Validation.GetErrors Method
[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]
Gets the value of the Errors attached property for the specified element.
Assembly: System.Windows (in System.Windows.dll)
'Declaration Public Shared Function GetErrors ( _ element As DependencyObject _ ) As ReadOnlyObservableCollection(Of ValidationError)
Parameters
- element
- Type: System.Windows.DependencyObject
The element to retrieve the errors for.
Return Value
Type: System.Collections.ObjectModel.ReadOnlyObservableCollection(Of ValidationError)A collection of ValidationError objects associated with the specified element.
| Exception | Condition |
|---|---|
| ArgumentNullException | element is Nothing. |
Show: