I would like to be able to query whether or not a service is running from a windows batch file. I know I can use:
sc query \"ServiceName\"
Try
sc query state= all
for a list of services and whether they are running or not.