How to abort shutdown in Windows (XP|Vista) programatically?

Posted by Piskvor on Stack Overflow See other posts from Stack Overflow or by Piskvor
Published on 2009-02-26T10:34:21Z Indexed on 2010/03/20 21:01 UTC
Read the original article Hit count: 308

Filed under:
|
|

I want to be able to detect and abort OS shutdown from my application, preferably by using the Windows API. I know that it is possible to do this manually using the command shutdown -a In the worst case, I could ShellExecute this, but I was wondering if there was a better way.

Also, how do I find out programatically that the OS is about to shut down, via the Win32 API?

© Stack Overflow or respective owner

Related posts about winapi

Related posts about shutdown