Hi folks,
I want to write a batch file that performs the following operation:
- Check if a Service is running
** If is it running, quit the batch
** If it is not running, start the service
The code samples I googled so far turned out not to be working, so I decided not to post them.
Starting a service is done by:
net start "SERVICENAME"
1) How can I check if a service is running, and how to make an if statement in a batchfile?
2) I'm a bit confused. What is the argument I have to pass onto the net start? The service name or its display name?