Back to Devexpress

WorksheetDataBindingCollection.Remove(WorksheetDataBinding) Method

officefileapi-devexpress-dot-spreadsheet-dot-worksheetdatabindingcollection-dot-remove-x28-devexpress-dot-spreadsheet-dot-worksheetdatabinding-x29.md

latest3.6 KB
Original Source

WorksheetDataBindingCollection.Remove(WorksheetDataBinding) Method

Removes the specified WorksheetDataBinding object from the collection.

Namespace : DevExpress.Spreadsheet

Assembly : DevExpress.Spreadsheet.v25.2.Core.dll

NuGet Package : DevExpress.Spreadsheet.Core

Declaration

csharp
void Remove(
    WorksheetDataBinding item
)
vb
Sub Remove(
    item As WorksheetDataBinding
)

Parameters

NameTypeDescription
itemWorksheetDataBinding

A WorksheetDataBinding object to be removed from the collection.

|

Remarks

To remove the WorksheetDataBinding object at the specified index in the collection, use the WorksheetDataBindingCollection.RemoveAt method. To remove all WorksheetDataBinding objects from the collection at once, use the WorksheetDataBindingCollection.Clear method.

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the Remove(WorksheetDataBinding) method.

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.

wpf-spreadsheet-bind-a-worksheet-to-generic-list-or-bindinglist-data-source/CS/DataBindingToListExample/MainWindow.xaml.cs#L48

csharp
if (this.weatherDataBinding != null)
    spreadsheetControl1.Document.Worksheets[0].DataBindings.Remove(this.weatherDataBinding);
#region #BindTheList

wpf-spreadsheet-bind-a-worksheet-to-generic-list-or-bindinglist-data-source/VB/DataBindingToListExample/MainWindow.xaml.vb#L50

vb
If Me.weatherDataBinding IsNot Nothing Then
    spreadsheetControl1.Document.Worksheets(0).DataBindings.Remove(Me.weatherDataBinding)
End If

See Also

WorksheetDataBindingCollection Interface

WorksheetDataBindingCollection Members

DevExpress.Spreadsheet Namespace