![]() |
Stopping a Service with batch files? (Xp)
I recently upgraded to Windows XP with a new knowledge that my (wireless) dwl-120 was a compatible version with it.
However im an avid gamer and right now my virtual life is spent bouncing around on World of Warcraft. After finishing the install and updates etc. etc. I found an extremely annoying problem. The service 'Wireless Zero Configuration' that searches for availble wirless networks every few moments creates unwanted lag. Simple enough problem to fix, just stop the service. When I reboot the computer I have to have this service run inorder to find my own network, but ive got to turn it off after it finds it to stop my game lag. So (finally) I get to my question. Is there a way that I could have a batch file run that turns this service off after 5-10 seconds? |
Stick the following line in a batch file, put it on your desktop and double click it when you want to stop it.
net stop wzcsvc If you want to restart it just put the following in another batch file: net start wzcsvc The word wzcsvc stands for "Wireless Zero Configuration Service." |
:) Thanks it would be much appreciated. Im new to the batch file thing...ive never really had a reason to mess with it. I found out how to stop the service in a batch.
Taskkill /F /FI "SERVICES eq WZCSVC" But im sure if your vb works ill just use that. I wouldnt mind knowing for my own knowledge though how to do this....anyone know how to make it wait 5-10 seconds? Without using Pause (which just waits for the user to hit a button.) |
Use the batch file above instead of VB script. It's easier!
|
We posted at the same time so I didnt see that :P.
I will use that as its cleaner. Wouldnt happen to know if there is a timing command do you? So that it would do it automatically. visual example: /wait 8 seconds net stop wzcsvc or something to that effect. |
You will have to find a pre 2000 machine to copy the command CHOICE.EXE from in order to get this to work, but the following will work:
choice /T:Y,10 /N net stop wzcsvc This will cause the batch file to wait 10 seconds to execute the next line once the batch file itself has been executed. |
Thanks for all of your help, its much appreciated.
The last thing I have a question about is...where can I find Choice.exe and where do i put it? I have windows 98 on my moms computer in the other room. *edit* nevermind I found it. (Windows\Command\Choice.com) ^ Thats where I found it...and i put it in Windows\System32..as thats where all the other commands are. However when it type choice in command prompt i get a 16 ms-dos subsystem error. |
Try right clicking on the file, choice.exe, and select compatibility mode and set it to Windows 95/98 and let me know what happens.
|
Same error:
16 bit ms-dos subsystem C:\Windows\system32\cmd.exe - choic The ntvdm cpu has encountered an illegal instruction. CS: 0537 IP: 0a86 OP:63 72 6f 73 6f.. close ~~ ignore. _______ Thats the error as it reads. |
Hmmm, let me try the VB script file instead.
I might not have it until tomorrow. |
Quote:
Nah. Dont worry about that, youve helped me enough as it is. I dont need the timer that bad, I can just click it after my computers started up and 10 seconds have passed...its much easier than going into services and shutting it off manually that way. Thanks for all of your help. |
you could also make a batch file that runs the command to stop the service, then launches your game... unless you're committed to having this done as soon as it can...
|
Have a look at sleep.exe from here:
http://www.computerhope.com/dutil.htm to momentarily pause the batch file. |
All times are GMT -8. The time now is 03:39 PM. |
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
Search Engine Optimization by vBSEO 3.6.0 PL2
© 2002-2012 Tilted Forum Project