ZenKensei Posted February 12, 2005 Share Posted February 12, 2005 Group, Working on a script to troubleshoot Microsoft's SMS Advanced client installation. The installation of advanced client relies on multiple factors such as the Admin$ share being accessable, the Server service being started, etc. So here's my problem. I know I can start & stop services inside AutoIt using something like:$ServerStart = RunWait(@ComSpec & " /c " & 'net start Server', "", @SW_HIDE) However, is there a way to query for the current state of the service so I don't have to blindly use the 'net start' and 'net stop' command? Say, using either a DLLCall function or an external program like PSService. I have nothing against using PSService if necessary, but if I use PSService how do I check the %State% variable once I run PSService query Server to see if the service is started?Thanks in advance for any advice,ZK Link to comment Share on other sites More sharing options...
Blue_Drache Posted February 12, 2005 Share Posted February 12, 2005 Group, Working on a script to troubleshoot Microsoft's SMS Advanced client installation. The installation of advanced client relies on multiple factors such as the Admin$ share being accessable, the Server service being started, etc. So here's my problem. I know I can start & stop services inside AutoIt using something like:$ServerStart = RunWait(@ComSpec & " /c " & 'net start Server', "", @SW_HIDE) However, is there a way to query for the current state of the service so I don't have to blindly use the 'net start' and 'net stop' command? Say, using either a DLLCall function or an external program like PSService. I have nothing against using PSService if necessary, but if I use PSService how do I check the %State% variable once I run PSService query Server to see if the service is started?Thanks in advance for any advice,ZK<{POST_SNAPBACK}>Route the commandline output to a txt file and read it with autoit. Lofting the cyberwinds on teknoleather wings, I am...The Blue Drache Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now