views:

98

answers:

3

I'm trying to change the default windows minimize effect with a C# winforms app.
I have no idea where to start.
Maybe I should set some kind of hook or something?
I just need to know, when a window likes to be minimized, the minimizing itself is no problem.
Anyone having any ideas??

A: 

You can use the following library to detect when a windows is being minimized: Using Window Messages to Implement Global System Hooks in C#

Giorgi
+1  A: 

You can use SetWindowsHookEx to set a WH_CALLWNDPROC hook I think you will get the SC_MINIMIZE message.

Also take a look at this code project post to see if it has what you need

rerun
+2  A: 

This CodeProject article shows how to create a Global System Hook in .NET.

http://www.codeproject.com/KB/system/globalsystemhook.aspx

Basically what you will want is this:

http://bytes.com/topic/c-sharp/answers/241866-capturing-onminimize-event

Except using a global system hook.

Robert Harvey