To create a new event handler on a control you can do this
c.Click += new EventHandler(mainFormButton_Click);
or this
c.Click += mainFormButton_Click;
and to remove an event handler you can do this
c.Click -= mainFormButton_Click;
But how do you remove all event handlers from an event?
Question&Answers:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…