wiring and unwiring event

c#

Solution

Possibly because there is other code in between that will trigger the event, and they don't want `eventHandler` to act on it. IMHO this isn't the best way to do things, but it's easy and it works.

If there is no other code in between there cannot possibly be a reason to remove and add the same event handler again.

Problem

In some cases I have found, developers unwire event then wire it again like this: ``` control.Click -= new eventHandler(eventHandler) control.Click += new eventHandler(eventHandler) ``` why do they do that?

Original source