The DxValidationProvider supplies a convenient path to validating input. However, it is more difficult to validate input in the GridControl. The DxValidateColumnProvider is an attempt to make this process more convenient.

DxValidateColumnProvider

The DxValidateColumnProvider manages views, columns within those views, and validation rules. Multiple grid views can be added to the provider. Column validation rules can then be added to the provider. A rule is associated with a column. Also, a rule to validate a complete grid row can be associated with the provider.

Like the DxValidationProvider, two default validation rules are supplied. First, the ConditionColumnProvider allows you to validate against a condition; it uses the same ConditionOperator which is used in the DxValidationProvider. The second rule is the CompareAgainstColumnValueValidator which allows you to validate the column value against a different column within the current grid row; it also uses the same CompareControlOperator which is used int eh DxValidationProvider. These two rules should handle many of your validation needs.

In addition, you can create custom validation rules. In general you will descend from the ColumnValidationRule. However, you can also implement the IColumnValidator. If you do so you will probably want to take advantage of the helper class DxValidateColumnProviderHelper which provides many of the tools used in the ColumnValidationRule.

NOTE: the call to set column error is invoked on the view. Since detail views are created on the fly, it is not yet possible to set column errors on detail views. It may work by creating the views/levels at design time but this functionality has not be investigated or tested.

DxValidateColumnProvider is not a toolbox component and does not have a UI designer. In other ways, it is designed to work similar to the DxValidationProvider. See Using the DxValidationProvider.