Archive

Archive for October, 2009

DIY WIFI Antenna Reception Booster

October 27, 2009 Leave a comment
Advertisements
Categories: null

Should I call Form.Dispose() after Form.Close() ?

October 22, 2009 Leave a comment

I bet most of .NET developers do not realized this part of MSDN documentation. It cost me 100%CPU usage for not knowing this.

 

http://msdn.microsoft.com/en-us/library/system.windows.forms.form.close.aspx
*The two conditions when a form is not disposed on Close is when (1) it is part of a multiple-document interface (MDI) application, and the form is not visible; and (2) you have displayed the form using ShowDialog. In these cases, you will need to call Dispose manually to mark all of the form’s controls for garbage collection

 

Important Quotes:

The two conditions when a form is not disposed on Close is when

(1) it is part of a multiple-document interface (MDI) application, and the form is not visible; and

(2) you have displayed the form using ShowDialog. In these cases, you will need to call Dispose manually to mark all of the form’s controls for garbage collection.

Categories: Dev, Windows
%d bloggers like this: