>...or because it is not supported on Windows Server 2003, this might explain why this does not work. This is the test server I have right now. So, I will have to move my tests into another server which will be Windows Server 2008. I will then assume that everything was ok with the code, if the default is ON, and SERVICE_CONTROL_PRESHUTDOWN would work.
Have you seen
http://msdn.microsoft.com/en-us/library/windows/desktop/ms685149%28v=vs.85%29.aspx ?
Regards. Al
"Violence is the last refuge of the incompetent." -- Isaac Asimov
"Never let your sense of morals prevent you from doing what is right." -- Isaac Asimov
Neither a despot, nor a doormat, be
Every app wants to be a database app when it grows up