Suspend Events

  • Thread starter Thread starter alexandre
  • Start date Start date
* "alexandre said:
Is there any function that Suspend all events for the Control object ?

Remove the handlers using 'RemoveHandler' (in VB.NET).
 
You need to use "-=" (minus equals):
this.button1.Click -= new System.EventHandler(this.button1_Click);

.... this is just the opposite of wiring it up:
this.button1.Click += new System.EventHandler(this.button1_Click);
 
Back
Top