Click here to Skip to main content
15,893,487 members
Home / Discussions / C#
   

C#

 
GeneralRe: Referring to a 2D array through a 1D array Pin
crushinghellhammer26-Jan-04 14:37
crushinghellhammer26-Jan-04 14:37 
GeneralRe: Referring to a 2D array through a 1D array Pin
Heath Stewart27-Jan-04 2:46
protectorHeath Stewart27-Jan-04 2:46 
GeneralRe: Referring to a 2D array through a 1D array Pin
crushinghellhammer27-Jan-04 8:21
crushinghellhammer27-Jan-04 8:21 
GeneralRe: Referring to a 2D array through a 1D array Pin
crushinghellhammer27-Jan-04 8:23
crushinghellhammer27-Jan-04 8:23 
GeneralRe: Referring to a 2D array through a 1D array Pin
Heath Stewart27-Jan-04 8:58
protectorHeath Stewart27-Jan-04 8:58 
GeneralRe: Referring to a 2D array through a 1D array Pin
crushinghellhammer27-Jan-04 9:01
crushinghellhammer27-Jan-04 9:01 
GeneralRe: Referring to a 2D array through a 1D array Pin
Heath Stewart27-Jan-04 9:08
protectorHeath Stewart27-Jan-04 9:08 
GeneralRe: Referring to a 2D array through a 1D array Pin
crushinghellhammer27-Jan-04 8:50
crushinghellhammer27-Jan-04 8:50 
GeneralPreview in Open Dialog box Pin
Shree26-Jan-04 6:23
Shree26-Jan-04 6:23 
GeneralRe: Preview in Open Dialog box Pin
Heath Stewart26-Jan-04 8:43
protectorHeath Stewart26-Jan-04 8:43 
GeneralUploading Images Pin
srt726-Jan-04 4:36
srt726-Jan-04 4:36 
GeneralRe: Uploading Images Pin
Mazdak26-Jan-04 4:52
Mazdak26-Jan-04 4:52 
GeneralRe: Uploading Images Pin
Mazdak26-Jan-04 4:57
Mazdak26-Jan-04 4:57 
GeneralRe: Uploading Images Pin
srt726-Jan-04 6:36
srt726-Jan-04 6:36 
GeneralRe: Uploading Images Pin
Mazdak26-Jan-04 6:52
Mazdak26-Jan-04 6:52 
Generalthreading in c# Pin
eman galal26-Jan-04 3:44
eman galal26-Jan-04 3:44 
GeneralRe: threading in c# Pin
Heath Stewart26-Jan-04 4:20
protectorHeath Stewart26-Jan-04 4:20 
GeneralExit from main Pin
thomasa26-Jan-04 3:08
thomasa26-Jan-04 3:08 
GeneralRe: Exit from main Pin
Heath Stewart26-Jan-04 3:13
protectorHeath Stewart26-Jan-04 3:13 
GeneralRe: Exit from main Pin
thomasa26-Jan-04 3:49
thomasa26-Jan-04 3:49 
GeneralRe: Exit from main Pin
Heath Stewart26-Jan-04 4:08
protectorHeath Stewart26-Jan-04 4:08 
You can't call it in the constructor, either. You should read about Windows Forms programming in the .NET Framework SDK. Some previous experience with Win32 and the Windows Management APIs would be helpful with understanding the message pump. In this case, however, the application pump hasn't started. See the line:
Application.Run(new FCMain());
This is actually broken down to something similar to the following when compiled:
FCMain form = new FCMain();
Application.Run(form);
Therefore, you should throw an exception from your constructor and handle put a try/catch around the statement above. This will not, however, catch other exceptions unless a SystemException is thrown that causes the main form to crash and returns execution to the entry point.

A better design, however, is to move whatever code causes the need to exit out of the FCMain form's constructor and put it in the entry point (or a method that the entry point calls).

 

-----BEGIN GEEK CODE BLOCK-----
Version: 3.21
GCS/G/MU d- s: a- C++++ UL@ P++(+++) L+(--) E--- W+++ N++ o+ K? w++++ O- M(+) V? PS-- PE Y++ PGP++ t++@ 5 X+++ R+@ tv+ b(-)>b++ DI++++ D+ G e++>+++ h---* r+++ y+++
-----END GEEK CODE BLOCK-----
Questionhacked? Pin
Anonymous26-Jan-04 2:47
Anonymous26-Jan-04 2:47 
AnswerRe: hacked? Pin
Thesisus26-Jan-04 3:05
Thesisus26-Jan-04 3:05 
GeneralRe: hacked? Pin
Heath Stewart26-Jan-04 3:10
protectorHeath Stewart26-Jan-04 3:10 
GeneralRe: hacked? Pin
Anonymous31-Jan-04 1:16
Anonymous31-Jan-04 1:16 

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.