A alexandre Nov 29, 2003 #1 Hi, Is there any function that Suspend all events for the Control object ? thanks
H Herfried K. Wagner [MVP] Nov 29, 2003 #2 * "alexandre said: Is there any function that Suspend all events for the Control object ? Click to expand... Remove the handlers using 'RemoveHandler' (in VB.NET).
* "alexandre said: Is there any function that Suspend all events for the Control object ? Click to expand... Remove the handlers using 'RemoveHandler' (in VB.NET).
A alexandre Nov 29, 2003 #3 Herfried said: Remove the handlers using 'RemoveHandler' (in VB.NET). Click to expand... thanks. i don't find how to do the same with C#
Herfried said: Remove the handlers using 'RemoveHandler' (in VB.NET). Click to expand... thanks. i don't find how to do the same with C#
T Tim Wilson [MVP] Nov 29, 2003 #4 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);
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);