views:

11

answers:

1

Can someone explain how you do this programatically in WPF?

<window Validation.Error="ItemError"></Window>

I am trying to set the attached event for Validation.Error through code, but cannot quite figure out how to do it.

+2  A: 

You use Validation.AddErrorHandler to do this:

Validation.AddErrorHandler(this, this.ItemError);
Reed Copsey
Thank you so very much!
Ristogod