Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

 The examples below are shown a starter examples, but you can gather every type of validation result by using the ValidationContext. To retrieve the validation context of an object, use the following code:

Code Block
var viewModelmodelValidation = new MyViewModel() as IModelValidation;
var validationContext = viewModelmodelValidation.ValidationContext;

Getting the number of or warnings and errors

...