Click here to Skip to main content
15,917,005 members
Home / Discussions / C#
   

C#

 
GeneralRe: Elegant way to develop a chronometer Pin
AlexB478-Jan-07 2:54
AlexB478-Jan-07 2:54 
QuestionHow to dispose a class Pin
Yustme8-Jan-07 0:14
Yustme8-Jan-07 0:14 
AnswerRe: How to dispose a class Pin
Martin#8-Jan-07 0:23
Martin#8-Jan-07 0:23 
AnswerRe: How to dispose a class Pin
Pete O'Hanlon8-Jan-07 0:30
mvePete O'Hanlon8-Jan-07 0:30 
GeneralRe: How to dispose a class Pin
Yustme8-Jan-07 0:48
Yustme8-Jan-07 0:48 
GeneralRe: How to dispose a class Pin
Guffa8-Jan-07 1:00
Guffa8-Jan-07 1:00 
GeneralRe: How to dispose a class Pin
Yustme8-Jan-07 1:03
Yustme8-Jan-07 1:03 
GeneralRe: How to dispose a class Pin
Scott Dorman8-Jan-07 17:12
professionalScott Dorman8-Jan-07 17:12 
For a class that is this simple, you really don't need a finalizer. Writing a proper finalizer is generally a non-trivial task as there are certain rules that need to be followed. Beyond that, adding a finalizer causes the runtime to place the object in the finalization queue when it is instantiated, which causes the garbage collection system additional work.

The finalizer will cause the Dispose method to be called if the coder forgets to call it, but that safety net usually comes at a higher cost than it's worth.

For a different view on how to implement the Disposable pattern, check out this article:

http://www.codeproject.com/useritems/idisposable.asp[^]

-----------------------------
In just two days, tomorrow will be yesterday.

GeneralRe: How to dispose a class Pin
Not Active8-Jan-07 2:36
mentorNot Active8-Jan-07 2:36 
GeneralRe: How to dispose a class Pin
Mircea Puiu8-Jan-07 3:39
Mircea Puiu8-Jan-07 3:39 
AnswerRe: How to dispose a class Pin
Guffa8-Jan-07 4:10
Guffa8-Jan-07 4:10 
GeneralRe: How to dispose a class Pin
Not Active8-Jan-07 4:15
mentorNot Active8-Jan-07 4:15 
GeneralRe: How to dispose a class Pin
Pete O'Hanlon9-Jan-07 3:33
mvePete O'Hanlon9-Jan-07 3:33 
GeneralRe: How to dispose a class Pin
Scott Dorman8-Jan-07 17:16
professionalScott Dorman8-Jan-07 17:16 
QuestionRowSource or Datasource in ComboBox Pin
phantanagu7-Jan-07 22:39
phantanagu7-Jan-07 22:39 
AnswerRe: RowSource or Datasource in ComboBox Pin
rizgar8-Jan-07 1:54
rizgar8-Jan-07 1:54 
QuestionHelp needed for Displaying Notification Icon Pin
Exelioindia7-Jan-07 22:37
Exelioindia7-Jan-07 22:37 
AnswerRe: Help needed for Displaying Notification Icon Pin
testy_proconsul7-Jan-07 23:18
testy_proconsul7-Jan-07 23:18 
GeneralRe: Help needed for Displaying Notification Icon Pin
Cormac M Redmond8-Jan-07 1:12
Cormac M Redmond8-Jan-07 1:12 
GeneralRe: Help needed for Displaying Notification Icon Pin
Exelioindia8-Jan-07 17:23
Exelioindia8-Jan-07 17:23 
AnswerRe: Help needed for Displaying Notification Icon Pin
Ravi Bhavnani8-Jan-07 2:50
professionalRavi Bhavnani8-Jan-07 2:50 
QuestionMultithreading Pin
indiaone7-Jan-07 21:21
indiaone7-Jan-07 21:21 
AnswerRe: Multithreading [modified] Pin
Shajeel7-Jan-07 21:55
Shajeel7-Jan-07 21:55 
GeneralRe: Multithreading Pin
indiaone7-Jan-07 23:04
indiaone7-Jan-07 23:04 
GeneralRe: Multithreading Pin
Shajeel7-Jan-07 23:07
Shajeel7-Jan-07 23:07 

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.