Back to Devexpress

ASPxDataValidationEventArgs.EditorPropertiesErrors Property

aspnet-devexpress-dot-web-dot-data-dot-aspxdatavalidationeventargs.md

latest2.3 KB
Original Source

ASPxDataValidationEventArgs.EditorPropertiesErrors Property

Gets a collection of editor errors.

Namespace : DevExpress.Web.Data

Assembly : DevExpress.Web.v25.2.dll

NuGet Package : DevExpress.Web

Declaration

csharp
public Dictionary<GridViewColumn, string> EditorPropertiesErrors { get; }
vb
Public ReadOnly Property EditorPropertiesErrors As Dictionary(Of GridViewColumn, String)

Property Value

TypeDescription
Dictionary<GridViewColumn, String>

The collection of errors.

|

Remarks

The grid uses validation rules specified in the properties of column editors and stores discovered validation errors in the EditorPropertiesErrors property that provides a collection of keys and values. Keys are columns. Values are validation error descriptions.

csharp
protected void ASPxGridView1_RowValidating(object sender, DevExpress.Web.Data.ASPxDataValidationEventArgs e) {
    ASPxGridView gridView = sender as ASPxGridView;
    e.EditorPropertiesErrors.Remove(gridView.Columns["OrderTime"]);
}

You can set the UseEditorPropertiesInDataControlValidation property to false to ignore column editors’ validation settings.

Global.asax:

csharp
void Application_Start(object sender, EventArgs e) {  
    ASPxWebControl.BackwardCompatibility.UseEditorPropertiesInDataControlValidation = false;  
}

See Also

ASPxDataValidationEventArgs Class

ASPxDataValidationEventArgs Members

DevExpress.Web.Data Namespace