Bapu Hirave · Aug 4, 2016

Windows service checks using Cache

Hello Cache experts,

Has anyone tried using Cache object script to check windows service is running or windows service installed or not on same computer or remote computer ? basically i am trying to develop cache program which will check "windows service" running or installed on current computer or remote computer. Based on the status of this windows service, i want to write some business logic in our application. Any suggestions will be more welcome

0 405
Discussion (1)1
Log in or sign up to continue

In this case you can use windows tool SC, to get information about services. 

and to work with SC, you can use $zf(-1), and it will looks something like this

set result=$zf(-1,"sc query messenger | FIND ""STATE"" | FIND ""RUNNING""")
if result'=0 write "Service messenger is not running"