Hi Fergus/Woody,
I'm assuming that your event data class derives from System.EventArgs...
Well instead, derive it from System.ComponentModel.CancelEventArgs.
Now, you can pass the 'Cancel' property back up the event chain and if
Cancel = True, don't do any event.
--
HTH,
-- Tom Spink, Über Geek
Please respond to the newsgroup,
so all can benefit
" System.Reflection Master "
==== Converting to 2002 ====
Remove inline declarations
"Fergus Cooney" <fi******@tesco.net> wrote in message
news:uG**************@TK2MSFTNGP12.phx.gbl...
Hi Woody,
If you have another field in EventData which the event handler can
set, this can inform the method that raises the event whether the ProposedValue
has been accepted or rejected.
Much like Handled in the KeyPressEventArgs of Control.KeyPress, and
Cancel in the CancelEventArgs of Form.Closing.
Regards,
Fergus