Suppressing and event call
Is there a way of suppressing an event call. I have a check Box when the box is checked checkchanged event is raised and I preform some checks if one of the checks fails I uncheck the checkbox but this creates a call to the event checkchanged. Is there a way of suppressing this second call?
patrickPosted Jun 25, 2009, 2:04 PM
CheckBox.CheckedChanged+=new System.EventHandler(this.CheckBox_CheckedChanged);
then add this method:
private void CheckBox_CheckedChanged(object sender, EventArgs e)
{
e.handled=true;
}
GordonPosted Jun 25, 2009, 1:10 PM
patrickPosted Jun 25, 2009, 12:39 PM