In this guide we will show you how to enable programs or custom scripts to run when Windows boots up. You may prefer that your Outlook opens up every time you log in to your computer in the morning at work, or you may want a custom batch file to run every time the desktop loads. Whatever your needs, this guide will show several convenient ways for configuring this behavior. We will also take a look at other methods programs use to run at boot and how to disable them.
In recent versions of Windows, we geeks no longer have to configure a hack or workaround to make a program run at boot, because can use the Task Scheduler utility provided in Windows. It’s best to use this method when at all possible, because this utility was specifically made for this purpose. Task Scheduler gives you a variety of options, such as whether or not to run the application with escalated privileges and setting the application to run only when certain conditions are met (AC power, network connection, etc).
To show you an example of what you can do with Task Scheduler, we will go through the steps required to make Event Viewer open up when you log in.
Go to the Start menu, type “Task Scheduler” and select it from the search results.
Task Scheduler can also be accessed in the Control Panel under Administrative Tools.
In the right side of the Task Scheduler menu, under Actions, select “Create Task.”
After clicking on that, you will see the following menu:
In the screenshot above, we have already put in a name and description for the task we’re creating. The only other thing we have done is check the box “Run with highest privileges.” Launching certain applications such as Event Viewer will typically result in a User Account Control prompt, unless you have UAC disabled on your system. When scheduling a task that requires administrator privileges, be sure to check this box, otherwise you will see an error in the notification area (lower right corner of the taskbar) and have to manually allow it.
Once you have filled out a name and description, click the “Triggers” tab, and then click “New.” You will be presented with a menu like the one below.
In this menu, under “Begin the task:” select “At log on.” Choose which user you would like the task to run for at log on, and configure any of the applicable advanced settings you would like. With the settings in the above screenshot, Event Viewer will run at every future log on as soon as user ‘geek’ logs in.
After you are finished configuring the new trigger, click OK and then select the “Actions” tab. Click “New” to make a new action.
Choose “Start a program” under the Action menu and then click “Browse” to point the new task to the program you would like it to start. In the example above, we have selected Event Viewer. If there are any arguments you need to run with your program, you can add those as well. For Event Viewer, none will be required, but other programs such as gaming servers will rely on them.
Click OK to exit out of the Actions menu. The “Conditions” and “Settings” tabs can be left alone, but feel free to check them out for a few more options – most of which are irrelevant for a task that runs a program at log on.
Click OK on the Create Task menu, and you are finished.
Another way to set a program or script to run at log on is using the Startup folder. You can access this folder in Windows 7 and previous versions of Windows by going to Start > All programs > Startup. On Windows 8 and previous versions, Startup can also be accessed in Explorer by browsing to “C:\Users\username\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup” (replacing ‘username’ with the name of your user).
To use the Startup folder to configure a program to run at boot, just make a shortcut to said program (Right click > Send to > Desktop) and put that shortcut in the Startup folder. Some programs use this method as their way of configuring themselves to run at start. If you have a program that keeps launching whenever you log in, there may be a shortcut to that program in the Startup folder.
Running Custom Scripts at Startup
Along with running programs at log on, you can also use Task Scheduler or the Startup folder to run custom batch scripts. Batch files contain commands that would normally be run in a command-line window. For example, the following code tells Windows to map a network share located on 192.168.1.1 to drive Z:.
net use z: \\192.168.1.1\share /USER:geek /P:Yes
To execute this line of code at startup, simply paste it into a text document and save the file as .bat. Place the .bat file in the Startup folder or use Task Scheduler to have your computer execute the line(s) of code whenever the specified user logs in.
Disabling programs from running at boot
There are a few ways that a program can configure itself to run at boot. The methods mentioned above are two of them, and after reading that you should have a good idea on how to disable programs that use those two methods. You should also see this guide for help with disabling programs that use the registry or other methods to run at boot.