Skip to main content
A newer version of this page is available. .
.NET Framework 4.5.2+
Row

WorksheetDataBindingCollection.Error Event

Occurs when a binding cannot be completed successfully.

Namespace: DevExpress.Spreadsheet

Assembly: DevExpress.Spreadsheet.v19.1.Core.dll

Declaration

event DataBindingErrorEventHandler Error

Event Data

The Error event's data class is DataBindingErrorEventArgs. The following properties provide information specific to this event:

Property Description
BindingDirection Indicates whose value is updated during binding.
ColumnIndex Gets the index of the column in which an error occurs.
DataBinding Gets a binding object whose binding caused an error.
ErrorType Indicates the cause of an error.
RowIndex Gets the index of the row in which an error occurs.

Remarks

The Error event indicates that an error occurs in cell range data binding. The DataBindingErrorEventArgs.ErrorType property details the cause of the error, the DataBindingErrorEventArgs.BindingDirection indicates whose value is being updated during binding.

Example

private void DataBindings_Error(object sender, DataBindingErrorEventArgs e) {
    string msg = String.Format("The error {0} occurs in attempt to {1} in row with index= {2}",
        e.ErrorType.ToString(), e.BindingDirection.ToString(), e.RowIndex);
    MessageBox.Show(msg, "Binding Error");
}

The following code snippets (auto-collected from DevExpress Examples) contain references to the Error event.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

See Also