Ok, this should be a really simple thing to do, and I'm either missing something, or going about it wrong.
Facts:
Silverlight 4, using the Toolkit and using DataForms / DataFields, but NOT using a validation summary.
Using a Templated Dataform, simple new / edit user form with usual fields like username, firstname, etc, plus Password and Confirm Password.
I want to validate so that if they are editing an existing user, and the password fields are blank, let it go through. Otherwise, make sure the passwords are the same. (This works already using a class level custom validator on my model.)
If the validation fails in #3, then alert the user by putting the usual clues on the Password field. (red border, message if you click in the field)
I can do everything now up through #3. But if the error occurs, then the error is shown as a form error, not a field error (which makes sense since the validation is on the class, not the property). I can not find a way to mark up my field to show the error. Since I'm not using a validation summary (for design reasons) the error just never shows up for the user.
Has anyone else done this, or can they send me to an example of a data form with password fields that does not use a Validation Summary so I can see how they solved it?
My two current options that I see are to manually mark the data field myself. OR, I'll build my own method of display full form errors that doesn't repeat errors like the validation summary does. (IE, I need a validation summary that ONLY shows form errors - not field errors.)
Thanks