Re: [FORM] Catching Minimize event
From: Imran Koradia (nospam_at_microsoft.com)
Date: 08/30/04
- Next message: Imran Koradia: "Re: [FORM] Catching Minimize event"
- Previous message: Didier BRETIN: "[FORM] Catching Minimize event"
- In reply to: Didier BRETIN: "[FORM] Catching Minimize event"
- Next in thread: Imran Koradia: "Re: [FORM] Catching Minimize event"
- Reply: Imran Koradia: "Re: [FORM] Catching Minimize event"
- Messages sorted by: [ date ] [ thread ]
Date: Mon, 30 Aug 2004 10:19:06 -0400
Override the WndProc method of the form and look for the WM_SYSCOMMAND
message. Here's info on when this message is sent and other details:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/WinUI/WindowsUserInterface/UserInput/KeyboardAccelerators/KeyboardAcceleratorReference/KeyboardAcceleratorMessages/WM_SYSCOMMAND.asp
You will not check the WParam for the SC_MINIMIZE value. Here's an example
of how to determine when the form is closed using the 'x' button. This one
checks for the SC_CLOSE value - you can modify it to check for SC_MINIMIZE
to determine when the window is minimized.
http://www.syncfusion.com/FAQ/WinForms/FAQ_c95c.asp#q862q
hope this helps..
Imran.
"Didier BRETIN" <dbr@informactis.com> wrote in message
news:413331b6$0$4370$626a14ce@news.free.fr...
> Hello,
>
> I would like to catch the "minimize event" of a form and then add an icon
> in the systray. I found how to add the icon, but I can't find the
"minimize
> event" of the form.
>
> What is it ?
>
> Regards.
>
> --
> Didier BRETIN
- Next message: Imran Koradia: "Re: [FORM] Catching Minimize event"
- Previous message: Didier BRETIN: "[FORM] Catching Minimize event"
- In reply to: Didier BRETIN: "[FORM] Catching Minimize event"
- Next in thread: Imran Koradia: "Re: [FORM] Catching Minimize event"
- Reply: Imran Koradia: "Re: [FORM] Catching Minimize event"
- Messages sorted by: [ date ] [ thread ]