Xceed Grid for WinForms v4.3 Documentation
SetDataBinding Method (ComboBoxEditor)


Xceed.Grid.v4.3 Assembly > Xceed.Grid.Editors Namespace > ComboBoxEditor Class : SetDataBinding Method
The data source used to populate the WinComboBox, typed as System.Object.
A string that specifies the table to bind to within the object returned by the DataSource property.
Sets the DataSource and DataMember properties at run time.
Syntax
'Declaration
 
Public Sub SetDataBinding( _

   ByVal dataSource As Object, _

   ByVal dataMember As String _

) 
'Usage
 
Dim instance As ComboBoxEditor

Dim dataSource As Object

Dim dataMember As String

 

instance.SetDataBinding(dataSource, dataMember)
public void SetDataBinding( 

   object dataSource,

   string dataMember

)

Parameters

dataSource
The data source used to populate the WinComboBox, typed as System.Object.
dataMember
A string that specifies the table to bind to within the object returned by the DataSource property.
Remarks

The following is a list of the supported data sources:

System.Data.DataTable Represents one table of in-memory data.
System.Data.DataView Represents a databindable, customized view of a System.Data.DataTable for sorting, filtering, searching, editing, and navigation.
System.Data.DataSet Represents an in-memory cache of data.
System.Data.DataViewManager Contains a default System.Data.DataViewSettingCollection for each System.Data.DataTable in a System.Data.DataSet.
Any component that implements the System.ComponentModel.IListSource interface. Provides functionality to an object to return a list that can be bound to a data source.
Any component that implements the System.Collections.IList interface. Represents a collection of objects that can be individually accessed by index.
Jagged arrays A jagged array is an array whose elements are arrays.

If the data source is a jagged array and rows are added or removed from the jagged array from outside of the WinComboBox, then the jagged array must be reassigned to the DataSource property in order for the modifications to be reflected in the WinComboBox.
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

ComboBoxEditor Class
ComboBoxEditor Members
DataSource Property
DataMember Property