Partager via


IDataErrorInfo.Item Property

Microsoft Silverlight will reach end of support after October 2021. Learn more.

Gets a message that describes any validation errors for the specified property or column name.

Namespace:  System.ComponentModel
Assembly:  System (in System.dll)

Syntax

'Declaration
ReadOnly Property Item ( _
    columnName As String _
) As String
string this[
    string columnName
] { get; }

Parameters

  • columnName
    Type: System.String
    The name of the property or column to retrieve validation errors for.

Property Value

Type: System.String
The validation error on the specified property; or nulla null reference (Nothing in Visual Basic) or Empty, if no errors are present.

Remarks

Use the Item property to get a single validation error message for a specified property or column. This message can represent multiple errors. If you want to represent multiple errors by using multiple custom error objects, implement the INotifyDataErrorInfo interface instead.

Examples

For an example of an implementation of this property, see the IDataErrorInfo class overview.

Version Information

Silverlight

Supported in: 5, 4

Silverlight for Windows Phone

Supported in: Windows Phone OS 7.1

Platforms

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.