batch file question

Soldato
Joined
1 Jun 2005
Posts
5,152
Location
Kent
i know that when run, batch files can execute multiple commands or programs, so im guessing its what i have to use to try adn get waht i want to happen.

what i want is to have a single file that can be run, either manualy or by windows scheduled task, that does all the sort of things i want run on a weekly basis, like run a virus scan with AVG anti virus, run a scan with AVG anti spyware, defrag my hdd, empty the recycle bin if it isnt already empty and things like that.

what i want to know is if doing all that is possible with a single batch file, or any sort of file? or do i have to set up a schedule for each and every program i want run and try and time it so that 1 program starts roughly when the previous one finishes?
 
Take a look at http://www.lifehacker.com/software/batch-scripts/.

Might give you some pointers.

Your AVG should be able to have tasks set? I use NOD32 and I can schedule it to do things for me whenever so that should be OK.

As for defrag, don't know what you use but you could use http://www.microsoft.com/technet/sysinternals/FileAndDisk/Contig.mspx coupled with http://www.softpedia.com/get/System/Hard-Disk-Utils/Power-Defragmenter.shtml to give you a free defragging solution. If you set up a batch file to run the contig.exe/Power Degfragmenter front end you should be able to do some command line stuff to specify the disk(s) you want done. Then set Windows Task Scheduler to run that batch file whenever you want it done.
 
Back
Top Bottom