Click here to Skip to main content
15,922,015 members
Home / Discussions / C#
   

C#

 
AnswerRe: howto create doc/view c#-apps? Pin
Kannan Kalyanaraman25-Mar-02 4:50
Kannan Kalyanaraman25-Mar-02 4:50 
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 
I have written a C# windows application. However, when the program is running, and I want to shut down windows, every program closes except my C# program; and windows does not shut down. It just waits. When I close my program manually, windows shuts down without a problem. The cause is that I have overriden the Closing event of the main form like this:

private void WindowsCloserForm_Closing(object sender, System.ComponentModel.CancelEventArgs e)
{
e.Cancel = true;
OpenDialog(false);
}

I wanted this behaviour however: closing the form should not end the program, but just hide it. (Via an icon in the system tray you can close the program)

If I do not override the Closing event, this problem does not occur. Can this be a bug in the framework, or am I forgetting something? Roll eyes | :rolleyes:

Thanks!
GeneralRe: Overriding the Closing event Pin
James T. Johnson24-Mar-02 21:51
James T. Johnson24-Mar-02 21:51 
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 

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.