Michael,
WM_ENDSESSION did the trick!
Eigil
Announcement
Collapse
No announcement yet.
Last message at closedown for tray app
Collapse
X
-
My bad, I read the question as "windows ending", not application ending.
WM_DESTROY would be a good choice in that case... assuming you don't want to do "cleanup" before the "END FUNCTION" of WinMain/PBMain.
Leave a comment:
-
He wasn't wanting an opportunity, just a message that fires in all cases. Opportunity would be WM_CLOSE or an End Session message giving him the choice to stop the process. He just needs to do cleanup...which is exactly what I do in Destroy messages. He wants to cleanup when the app ends, which can be by normal means or when windows shuts down.
Leave a comment:
-
Your Window should always at least get the WM_DESTROY too, and is a for-sure message where the End Sessions can be aborted by any app.
Leave a comment:
-
Yes, Roger you've been a stranger too. Haven't seen you around the PlanetSquires forum for a while. FireFly 3 is coming along very well. I am very happy with it and I am pushing its development hard in order to get it done.
Leave a comment:
-
Well, I didn't want to go that detailed, but yes the NC messages fire last. Haven't seen a post from you in a while. How's my next version of FireFly coming?
I used to use the NC Activate messages for Top Most fixes in Win 98 too.
Leave a comment:
-
WM_NCDESTROY is sent after WM_DESTROY. At that point you can be assured that all windows in the application have been destroyed.
Leave a comment:
-
Your Window should always at least get the WM_DESTROY too, and is a for-sure message where the End Sessions can be aborted by any app.
Leave a comment:
-
Last message at closedown for tray app
Hi,
I have a Tray application and would like to do some clean up when theapplication ends. If the user exit via my Exit menu everything is ok, BUT when some of my users just closes down the computer without closing the app in a normal way the cleanup is not executetd. What will be the message sent to the message pump to look for? I have tried WM_ Command +%WM_Close, WS_Syscommand + sc_Close, but none seem to be the right one.
?
EigilTags: None
Leave a comment: