-
Win32 Messages
Hi everyone,
How can i receive messages from windows in my windowless application? My app is a single process that runs in the backgorund and has no window. I need to receive a WTSRegisterSessionNotification with WM_WTSSESSION_CHANGE and also the WM_ENDSESSION message but I have no window (so no handle). How can it be achieved? There MUST be a way to do that without creating an unvisible window.
Thanks in advance!
-
Re: Win32 Messages
WTSRegisterSessionNotification registers reception of session changes to a particular window. so indeed there MUST be a window. It strikes me somewhat odd you would even want to do this without a window.
If you have a service (and typically no window) you would want to use RegisterServiceCtrlHandlerEx() instead and write your own service handler to do (more or less) the same.