• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint

Task Scheduler

Using the Task Scheduler, you can set up any program or script (or even open a document) to be run automatically at predetermined times. This utility is very useful for running system maintenance programs or your own scripts and programs when you can't be around to execute them manually.

#377

You could even use the Task Scheduler to run a script that starts or stops a specific system service because services can be started and stopped with this command line:

net start "service name here"

or

net stop "service name here"

Most folks don't even need to think about this capability, but if you are a software developer and use a special debugging or testing service, this capability might be handy to start it up when you log in. Remember that there is no "when I log off" scheduler entry, so you can't automate shutting off the process when someone logs out.

You can also cause a specific script or program to run when the system boots or when a user (any user) logs on. Why is this different from putting the script or program in the Startup group for All Users? Well, the Task Scheduler lets you specify the logon name to use for this login task. For example, whenever a user logs on, you can have the Task Scheduler run a program with Administrative privileges to record information in a protected file. Using the Task Scheduler this way is similar to using the Run As option. (See Chapter 32, "Managing Users," for more details about Run As.)



PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint