Click here to Skip to main content
15,900,378 members
Home / Discussions / C#
   

C#

 
GeneralRe: Accessing properties as an array Pin
OmegaSupreme17-Feb-04 12:43
OmegaSupreme17-Feb-04 12:43 
Generalapplication uses all the memory Pin
amadeonMk16-Feb-04 21:23
amadeonMk16-Feb-04 21:23 
GeneralRe: application uses all the memory Pin
Heath Stewart17-Feb-04 5:20
protectorHeath Stewart17-Feb-04 5:20 
GeneralRe: application uses all the memory Pin
Chen Pang17-Feb-04 23:13
Chen Pang17-Feb-04 23:13 
GeneralRe: application uses all the memory Pin
Heath Stewart18-Feb-04 3:55
protectorHeath Stewart18-Feb-04 3:55 
Generalclosing the main form after loading another form Pin
killermoses16-Feb-04 19:31
killermoses16-Feb-04 19:31 
GeneralRe: closing the main form after loading another form Pin
John Kuhn16-Feb-04 19:38
John Kuhn16-Feb-04 19:38 
GeneralRe: closing the main form after loading another form Pin
obelisk2916-Feb-04 19:48
obelisk2916-Feb-04 19:48 
Every form you create acts just like a class would so you could just do.
MySecondForm form = new MySecondForm();
form.Show();
this.Dispose();

The 'this' keyword refers to the object you're form is derived from including all of the custom objects
and functions you have put in. You could also just say 'Dispose();' instead of 'this.Dispose();' but
for keeping clarity it's better to use the this keyword.

You could also say 'this.Hide();' but then it keeps that form in memory which when you're dealing
with multiple forms this could eat up your memory pretty quickly. I just take my forms out of
memory when I don't need them.

------------------

I'm naked under my clothes...
GeneralRe: closing the main form after loading another form Pin
killermoses17-Feb-04 2:02
killermoses17-Feb-04 2:02 
GeneralRe: closing the main form after loading another form Pin
Heath Stewart17-Feb-04 5:26
protectorHeath Stewart17-Feb-04 5:26 
GeneralRe: closing the main form after loading another form Pin
Charlie Williams17-Feb-04 4:19
Charlie Williams17-Feb-04 4:19 
GeneralCalling Managed C++ code in a C# App Pin
granderson16-Feb-04 12:28
granderson16-Feb-04 12:28 
GeneralRe: Calling Managed C++ code in a C# App Pin
obelisk2916-Feb-04 19:41
obelisk2916-Feb-04 19:41 
GeneralMetrics 2 english 2 twips 2 whatever Pin
Tomaž Štih16-Feb-04 11:58
Tomaž Štih16-Feb-04 11:58 
GeneralRe: Metrics 2 english 2 twips 2 whatever Pin
Heath Stewart17-Feb-04 3:52
protectorHeath Stewart17-Feb-04 3:52 
GeneralPrinting from a webservice Pin
nathanreynolds16-Feb-04 11:31
nathanreynolds16-Feb-04 11:31 
GeneralRe: Printing from a webservice Pin
Heath Stewart17-Feb-04 3:26
protectorHeath Stewart17-Feb-04 3:26 
GeneralRe: Printing from a webservice Pin
nathanreynolds17-Feb-04 10:55
nathanreynolds17-Feb-04 10:55 
GeneralRe: Printing from a webservice Pin
Heath Stewart17-Feb-04 13:13
protectorHeath Stewart17-Feb-04 13:13 
GeneralRe: Printing from a webservice Pin
nathanreynolds17-Feb-04 16:27
nathanreynolds17-Feb-04 16:27 
GeneralRe: Printing from a webservice Pin
Heath Stewart17-Feb-04 19:32
protectorHeath Stewart17-Feb-04 19:32 
GeneralRe: Printing from a webservice Pin
nathanreynolds18-Feb-04 2:27
nathanreynolds18-Feb-04 2:27 
GeneralRe: Printing from a webservice Pin
Heath Stewart18-Feb-04 4:11
protectorHeath Stewart18-Feb-04 4:11 
GeneralA GDI+ newbie problem Pin
cemlouis16-Feb-04 11:28
cemlouis16-Feb-04 11:28 
GeneralRe: A GDI+ newbie problem Pin
Charlie Williams16-Feb-04 16:14
Charlie Williams16-Feb-04 16: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.