Kill a Task, have a 10 second delay, then restart task
Posted: 09 Feb 2011 11:03
Hello,
I have 50 computers that have Virtual PC 2007 (VPC) installed. I need to upgrade VPC to SP1. When I begin the upgrade, I get a little warning like this:
I usually work around the error by starting Task Manager, killing explorer.exe, then click the retry button in the above image and the installation completes. Then, I have to open Task Manager again, then restart explorer.exe.
Obviously the kill/start process of explorer.exe will get quite tedious when upgrading VPC on these computers.
I'm working on a batch script that will kill explorer.exe. Then, I would like there to be a 10 second pause so I can finish the installation of VPC, then the script will automatically restart explorer.exe.
Unfortunately I'm not much of a scripter so I'm getting stuck at the time delay and restarting explorer.
For killing the task I'm thinking of using the simple taskkill /f /im "explorer.exe"
For restarting the task can I just use the simple "start explorer.exe" command?
I don't really need a scripting marvel, just something to the point that works. If someone can help me through a little script together, that would be great. Thanks so much for the help.
I have 50 computers that have Virtual PC 2007 (VPC) installed. I need to upgrade VPC to SP1. When I begin the upgrade, I get a little warning like this:
I usually work around the error by starting Task Manager, killing explorer.exe, then click the retry button in the above image and the installation completes. Then, I have to open Task Manager again, then restart explorer.exe.
Obviously the kill/start process of explorer.exe will get quite tedious when upgrading VPC on these computers.
I'm working on a batch script that will kill explorer.exe. Then, I would like there to be a 10 second pause so I can finish the installation of VPC, then the script will automatically restart explorer.exe.
Unfortunately I'm not much of a scripter so I'm getting stuck at the time delay and restarting explorer.
For killing the task I'm thinking of using the simple taskkill /f /im "explorer.exe"
For restarting the task can I just use the simple "start explorer.exe" command?
I don't really need a scripting marvel, just something to the point that works. If someone can help me through a little script together, that would be great. Thanks so much for the help.