NCombobox databinding


Author
Message
Sourena Mansouri
Sourena Mansouri
Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)
Group: Forum Members
Posts: 1, Visits: 1
Hi All,

I'm having a newbie issue. With Microsoft combobox I can do a binding such as the following:

// Populate the list
comboBoxState.DataSource = DataSet;
// Define the field to be displayed
comboBoxState.DisplayMember = "States.StateName";
// Define the field to be used as the value
comboBoxState.ValueMember = "States.StateID";
// Bind the selected value of the the ComboBox to the
// Region field of the current Customer
comboBoxState.DataBindings.Add("SelectedValue", DataSet, "Customers.State");

However the DataSource, DisplayMember, ValueMember properties are not available in NComboBox as well as the SelectedValue binding. What alternative method do I have to do the binding that I need here, to look up and fill the text from one table and on selection write the ID to another table.

Than you all in advance.

Cheers.
Angel Chorbadzhiev
Angel Chorbadzhiev
Supreme Being (142 reputation)Supreme Being (142 reputation)Supreme Being (142 reputation)Supreme Being (142 reputation)Supreme Being (142 reputation)Supreme Being (142 reputation)Supreme Being (142 reputation)Supreme Being (142 reputation)Supreme Being (142 reputation)
Group: Forum Members
Posts: 139, Visits: 184

Hello S.Mann,

Currently NComboBox and NListBox doesn't support databinding.

You have to add or remove the items manually.

Regards,

Angel.


GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search