Click here to Skip to main content
16,008,490 members
Home / Discussions / C#
   

C#

 
GeneralRe: dilema with strings and richtextbox Pin
Tyrus18228-Dec-04 13:00
Tyrus18228-Dec-04 13:00 
GeneralperformanceCounter woes Pin
sween327-Dec-04 16:38
sween327-Dec-04 16:38 
GeneralDBAdapter.Fill(), datatype matching. Pin
zecodela27-Dec-04 15:45
zecodela27-Dec-04 15:45 
GeneralRe: DBAdapter.Fill(), datatype matching. Pin
sreejith ss nair27-Dec-04 18:37
sreejith ss nair27-Dec-04 18:37 
GeneralRe: DBAdapter.Fill(), datatype matching. Pin
Heath Stewart27-Dec-04 20:12
protectorHeath Stewart27-Dec-04 20:12 
GeneralRe: DBAdapter.Fill(), datatype matching. Pin
Heath Stewart27-Dec-04 20:20
protectorHeath Stewart27-Dec-04 20:20 
GeneralContainer Window for Minimized forms Pin
hybrid7927-Dec-04 14:25
hybrid7927-Dec-04 14:25 
GeneralRe: Container Window for Minimized forms Pin
Heath Stewart27-Dec-04 20:10
protectorHeath Stewart27-Dec-04 20:10 
Within your own application there's not much you cannot do. If you want to capture minimized windows from other processes that's a different matter. The Windows shell (Windows Explorer) handles this and there's not much you can do.

You could install a Windows hook using the WH_CBT (0x5) message and handling the HCBT_MINMAX (0x1) notification message in your CBTProc callback. These refer to native functionality so you'll need to be familiar with P/Invoke. Above all - be careful. Windows system hooks are hooks for messages throughout the entire system. Your code must be efficient and robust, meaning that it can fail gracefully and cleans itself up if problems occur.

For more information about using system hooks in C#/.NET, read Using Hooks from C#[^] here on CodeProject. Do be sure to read the information in the Platform SDK specifically for the WH_CBT hook for information about the callback parameter values (like which ones pass you the HWND (an IntPtr in managed code) that you can use in calls to other native APIs).

While you won't be able to stop the default behavior using this approach (and I honestly can't think of any other hooks or sinks you can use from all my experience and research), you could P/Invoke other native APIs like GetWindowText to collect information about windows and display some captioned icon in a window of your choosing.

This posting is provided "AS IS" with no warranties, and confers no rights.

Software Design Engineer
Developer Division Sustained Engineering
Microsoft

[My Articles] [My Blog]
QuestionHow to assosiate files to my program Pin
mikker_12327-Dec-04 12:00
mikker_12327-Dec-04 12:00 
AnswerRe: How to assosiate files to my program Pin
Heath Stewart27-Dec-04 20:01
protectorHeath Stewart27-Dec-04 20:01 
QuestionImageList SizeMode ? Pin
geestje27-Dec-04 11:21
geestje27-Dec-04 11:21 
AnswerRe: ImageList SizeMode ? Pin
Heath Stewart27-Dec-04 19:58
protectorHeath Stewart27-Dec-04 19:58 
GeneralRe: ImageList SizeMode ? Pin
geestje28-Dec-04 7:07
geestje28-Dec-04 7:07 
GeneralRe: ImageList SizeMode ? Pin
Heath Stewart28-Dec-04 7:11
protectorHeath Stewart28-Dec-04 7:11 
GeneralRe: ImageList SizeMode ? Pin
geestje28-Dec-04 7:20
geestje28-Dec-04 7:20 
GeneralRe: ImageList SizeMode ? Pin
Heath Stewart28-Dec-04 7:23
protectorHeath Stewart28-Dec-04 7:23 
GeneralC# Multiple forms... Pin
afrodriguez27-Dec-04 10:18
afrodriguez27-Dec-04 10:18 
GeneralRe: C# Multiple forms... Pin
DavidNohejl27-Dec-04 13:01
DavidNohejl27-Dec-04 13:01 
GeneralRe: C# Multiple forms... Pin
Matt Gerrans27-Dec-04 14:33
Matt Gerrans27-Dec-04 14:33 
GeneralRe: C# Multiple forms... Pin
afrodriguez27-Dec-04 15:24
afrodriguez27-Dec-04 15:24 
GeneralRe: C# Multiple forms... Pin
Matt Gerrans27-Dec-04 23:47
Matt Gerrans27-Dec-04 23:47 
GeneralRe: C# Multiple forms... Pin
Heath Stewart28-Dec-04 7:13
protectorHeath Stewart28-Dec-04 7:13 
GeneralRe: C# Multiple forms... Pin
afrodriguez27-Dec-04 15:21
afrodriguez27-Dec-04 15:21 
Generalcustom controls and design time Pin
Tyrus18227-Dec-04 10:17
Tyrus18227-Dec-04 10:17 
GeneralRe: custom controls and design time Pin
Jay Shankar27-Dec-04 14:47
Jay Shankar27-Dec-04 14:47 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.