From the thread – Fire windows service stop event I know how to fire an event whenever a system service has stopped.
Now I want to fire an event when a service starts. But I can’t find any service control code relating service starting. Is there anther way to implement it?
Any ideas will be appreciated.
Check out
NotifyServiceStatusChangehttp://msdn.microsoft.com/en-us/library/windows/desktop/ms684276(v=vs.85).aspx
You could also use WMI:
How can I monitor status changes of windows services under windows xp?