Stop, wait, and start service using a scheduled task in Windows 7
Posted on 2010-09-20
I need a script that I can schedule to run at the same time everyday that will Stop a service, wait an hour, then restart the service again. I'm used to DOS batch scripts in WinXP. Win7 has a level of security I can't seem to get through.
The goal will be to Stop CarboniteService for an hour so that the Win7 backup can run, then starting CarboniteService back up.
The simple-minded DOS batch equivalent is:
net stop CarboniteService
<wait 1 hour>
Net start CarboniteService