Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Multiple ComboBox with single DataSource

I have 2 combo boxes that are tied up to a single binding source in a dataset. When I select an item in one of the combo boxes, they both change. I don't have code in the combobox themselves but I do have the dataset fill:

this.cLIENT_BranchesTableAdapter.Fill(this.gcDataSet.CLIENT_Branches);

What could be causing this?

like image 941
J.P Masangcay Avatar asked Feb 08 '23 19:02

J.P Masangcay


1 Answers

Give each ComboBox their own BindingSource:

comboBox1.DataSource = new BindingSource(source, string.Empty);
comboBox2.DataSource = new BindingSource(source, string.Empty);
like image 72
LarsTech Avatar answered Feb 15 '23 10:02

LarsTech