title: Windows command to get service status?
body: <p>I need to know the status of a service at the end of my batch script which restarts services using "net stop thingie" and "net start thingie".</p>
  
  <p>In my most favorite ideal world, I would like to e-mail the state to myself, to read on cold winter nights, to reassure myself with the warmth and comfort of a server that I know is running right.</p>
  
  <p>Just for you to know, I'm using a Windows server 2003 platform, and a batch file seemed the best choice. I don't mind using something else, and would be very open to suggestions, but just for the sake of knowledge (as a zombie craves brains, I thought, why not inflate my own), is there a command that allows me to check on the status of a service, in command line?</p>
  
  <p>Should I just redirect the output of the command to a file?</p>
  
  <p>Where the hell are my pants? (Gosh, I really do hope the humor inserted in this will not insult anyone. It's Wednesday morning, and humor I do need too :P)</p>
  
  <p>[Edit:] The solution I used is (no longer) available for download from --link redacted--</p>
  
  <p>It is used as a task set to be executed during the night, and checking my e-mail in the morning, I see whether or not the service has correctly restarted.</p>