954,180 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

How to make my program detecct when the computer is going to LOGOFF or SHUTDOWN

am currently building a program that runs as a background process, but due to the loops inside it, Windows fails to Close it when it goes into either shutdown or LOGOFF mode. It is a GUI program that uses WINMAIN but without a GUI interface. Can you tell me how to make the program detect when the computer is going to shutdown so that it can terminate imediately.

Mahen
Junior Poster
144 posts since Aug 2004
Reputation Points: 10
Solved Threads: 2
 

look up....
WM_QUERYENDSESSION
WM_ENDSESSION

Stoned_coder
Junior Poster
164 posts since Jul 2005
Reputation Points: 19
Solved Threads: 5
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You