Click here to Skip to main content
15,921,941 members
Home / Discussions / C#
   

C#

 
GeneralI need help with this question Pin
25-Mar-02 0:21
suss25-Mar-02 0:21 
GeneralRe: I need help with this question Pin
BLaZiNiX26-Mar-02 19:01
BLaZiNiX26-Mar-02 19:01 
QuestionListView with CheckedItems ??? Pin
gicio24-Mar-02 23:54
gicio24-Mar-02 23:54 
QuestionAny way to create a better looking TabControl? Pin
24-Mar-02 23:27
suss24-Mar-02 23:27 
AnswerRe: Any way to create a better looking TabControl? Pin
25-Mar-02 4:20
suss25-Mar-02 4:20 
QuestionReplace parts of an object in an ArrayList.But how ??? Pin
gicio24-Mar-02 23:18
gicio24-Mar-02 23:18 
GeneralOverriding the Closing event Pin
24-Mar-02 21:39
suss24-Mar-02 21:39 
GeneralRe: Overriding the Closing event Pin
James T. Johnson24-Mar-02 21:51
James T. Johnson24-Mar-02 21:51 
Windows is just doing what you asked it to Smile | :)

You need to override the WndProc of the form and catch the WM_QUIT message, one of the parameters tells you what is telling the form to close; if its the user then you should continue as you do; otherwise let the program shutdown. Look up in MSDN what the values you need for WM_QUIT and what lParam and wParam are.

Almost had me stumped on this one, then I remembered I tried doing the same in an MFC program and that was what I had to do Smile | :)

James

Sonork ID: 100.11138 - Hasaki
"Smile your little smile, take some tea with me awhile.
And every day we'll turn another page.
Behind our glass we'll sit and look at our ever-open book,
One brown mouse sitting in a cage."
"One Brown Mouse" from Heavy Horses, Jethro Tull 1978

GeneralRe: Overriding the Closing event Pin
David Wengier25-Mar-02 0:11
David Wengier25-Mar-02 0:11 
GeneralCreate Control at Runtime Pin
Mazdak24-Mar-02 20:50
Mazdak24-Mar-02 20:50 
GeneralRe: Create Control at Runtime Pin
James T. Johnson24-Mar-02 21:22
James T. Johnson24-Mar-02 21:22 
QuestionCan I generate ActiveX Document From C#? Pin
24-Mar-02 18:31
suss24-Mar-02 18:31 
AnswerRe: Can I generate ActiveX Document From C#? Pin
James T. Johnson24-Mar-02 18:43
James T. Johnson24-Mar-02 18:43 
GeneralWeird GDI+ rectangle drawing Pin
24-Mar-02 11:56
suss24-Mar-02 11:56 
GeneralRe: Weird GDI+ rectangle drawing Pin
James T. Johnson24-Mar-02 21:56
James T. Johnson24-Mar-02 21:56 
GeneralRe: Weird GDI+ rectangle drawing Pin
25-Mar-02 4:05
suss25-Mar-02 4:05 
GeneralSimple Question Pin
Mazdak24-Mar-02 6:14
Mazdak24-Mar-02 6:14 
GeneralRe: Simple Question Pin
James T. Johnson24-Mar-02 9:33
James T. Johnson24-Mar-02 9:33 
GeneralRe: Simple Question Pin
Mazdak24-Mar-02 19:29
Mazdak24-Mar-02 19:29 
GeneralPrinting Pin
BLaZiNiX23-Mar-02 23:39
BLaZiNiX23-Mar-02 23:39 
GeneralRe: Printing Pin
Mazdak24-Mar-02 4:47
Mazdak24-Mar-02 4:47 
GeneralRe: Printing Pin
BLaZiNiX24-Mar-02 6:10
BLaZiNiX24-Mar-02 6:10 
GeneralRe: Printing Pin
Mazdak24-Mar-02 6:55
Mazdak24-Mar-02 6:55 
GeneralRe: Printing Pin
BLaZiNiX24-Mar-02 8:14
BLaZiNiX24-Mar-02 8:14 
QuestionHow to call the default handler? Pin
Nish Nishant23-Mar-02 21:43
sitebuilderNish Nishant23-Mar-02 21:43 

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.