BarCodeControl.Validate() Method

Indicates whether or not the bar code is correctly rendered.

Namespace: DevExpress.XtraEditors

Assembly: DevExpress.XtraEditors.v21.2.dll


public BarCodeError Validate()


Type Description

A BarCodeError enumeration value, identifying the error (BarCodeError.None if the bar code validation succeeds).


Call the Validate method after specifying bar code settings (e.g., in the Paint event handler) to make sure that the resulting bar code will be properly rendered.

When validation fails (indicating that the bar code is not rendered), the control displays an error message corresponding to one of the PreviewStringId enumeration values.

To learn about possible errors and the corresponding text displayed in a control, see the BarCodeError enumeration.

See Also