Edit this page

Validation Error Indicator Remains


You apply a row-level validation setting a custom ValidationResult when invoking the RowValidating event. Then you correct the value, but the error indicator is still displayed.


The problem comes from the fact that you are introducing some user errors when validating RadGridView through the RowValidating event.


With Q3 2013 official release we have introduced a new property for GridViewRowEditEndedEventArgs - UserDefinedErrors. It contains all user errors for the row being edited. By handling the RowEditEnded event you can clear these errors and restore the valid state of the row.

Example 1 shows how the property can be used.

Example 1: Clearing user-defined errors

private void rgvTest_RowEditEnded(object sender, GridViewRowEditEndedEventArgs e)
    if (e.EditAction == GridViewEditAction.Cancel)
Private Sub rgvTest_RowEditEnded(ByVal sender As Object, ByVal e As GridViewRowEditEndedEventArgs)
    If e.EditAction = GridViewEditAction.Cancel Then
    End If
End Sub

See Also

Is this article helpful? Yes / No
Thank you for your feedback!

Give article feedback

Tell us how we can improve this article