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

C#

 
GeneralRe: Clearing Panel from Event Handler Pin
Heath Stewart24-Jun-04 12:25
protectorHeath Stewart24-Jun-04 12:25 
GeneralRe: Clearing Panel from Event Handler Pin
RobertVG24-Jun-04 13:55
RobertVG24-Jun-04 13:55 
GeneralRe: Clearing Panel from Event Handler Pin
RobertVG24-Jun-04 13:56
RobertVG24-Jun-04 13:56 
GeneralRe: Clearing Panel from Event Handler Pin
RobertVG24-Jun-04 14:11
RobertVG24-Jun-04 14:11 
GeneralConcurrency Pin
IamADotNetGuy24-Jun-04 10:01
IamADotNetGuy24-Jun-04 10:01 
GeneralRe: Concurrency Pin
Dave Kreskowiak24-Jun-04 10:17
mveDave Kreskowiak24-Jun-04 10:17 
GeneralRe: Concurrency Pin
Xiangyang Liu 刘向阳24-Jun-04 17:13
Xiangyang Liu 刘向阳24-Jun-04 17:13 
GeneralDetaching event handlers Pin
Flack24-Jun-04 9:57
Flack24-Jun-04 9:57 
Hello,

In one of the apps I came across in a book Im reading, a form attaches itself to the SystemEvents.UserPreferenceChangedEvent. In the Dispose method of this form, it detaches itself.

My question is this: If the form is being disposed anyway, when you close it, why do you need to explicitly detach yourself from this event? I have never seen the need to detach events in the Dispose method before (for example, if the form is attached to the regular mouse events). What would happen if I didnt detach the form from the event?

Also, do controls automatically remove themselves form any events they are attached to when they are deleted/removed from the form?

Thanx for the help Big Grin | :-D
-Flack
GeneralRe: Detaching event handlers Pin
Heath Stewart24-Jun-04 10:27
protectorHeath Stewart24-Jun-04 10:27 
GeneralNeed PDF help Pin
Unforsacable24-Jun-04 9:35
Unforsacable24-Jun-04 9:35 
GeneralRe: Need PDF help Pin
Heath Stewart24-Jun-04 9:47
protectorHeath Stewart24-Jun-04 9:47 
GeneralRe: Need PDF help Pin
Anonymous24-Jun-04 11:14
Anonymous24-Jun-04 11:14 
GeneralRe: Need PDF help Pin
Heath Stewart24-Jun-04 12:30
protectorHeath Stewart24-Jun-04 12:30 
GeneralRe: Need PDF help Pin
Daniel Turini24-Jun-04 11:35
Daniel Turini24-Jun-04 11:35 
GeneralPassing parameters to Contents.htm file Pin
IrishSonic24-Jun-04 9:30
IrishSonic24-Jun-04 9:30 
GeneralRe: Passing parameters to Contents.htm file Pin
Dave Kreskowiak24-Jun-04 9:41
mveDave Kreskowiak24-Jun-04 9:41 
Generalproblem Pin
RomanD24-Jun-04 9:07
RomanD24-Jun-04 9:07 
GeneralRe: problem Pin
Dave Kreskowiak24-Jun-04 9:30
mveDave Kreskowiak24-Jun-04 9:30 
GeneralRe: problem Pin
RomanD24-Jun-04 12:04
RomanD24-Jun-04 12:04 
QuestionHow do I FULLY unregister a COM+ component programmatically? Pin
Boyd Campbell24-Jun-04 7:14
Boyd Campbell24-Jun-04 7:14 
AnswerRe: How do I FULLY unregister a COM+ component programmatically? Pin
Heath Stewart24-Jun-04 9:40
protectorHeath Stewart24-Jun-04 9:40 
GeneralRe: How do I FULLY unregister a COM+ component programmatically? Pin
Boyd Campbell24-Jun-04 10:03
Boyd Campbell24-Jun-04 10:03 
GeneralRe: How do I FULLY unregister a COM+ component programmatically? Pin
Heath Stewart24-Jun-04 10:12
protectorHeath Stewart24-Jun-04 10:12 
GeneralRe: How do I FULLY unregister a COM+ component programmatically? Pin
Boyd Campbell24-Jun-04 10:32
Boyd Campbell24-Jun-04 10:32 
GeneralRe: How do I FULLY unregister a COM+ component programmatically? Pin
Heath Stewart24-Jun-04 11:19
protectorHeath Stewart24-Jun-04 11:19 

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.