You are using something that is present in the background of WinForms called "CurrencyManager".
Its task is to synchronize the "current record" across all connecting controls that belong to the same data source.
For example, if you added a label and linked it to the same list and linked it so that it displayed a property of one of the objects, it always displayed the property value of the same object that you selected in the drop-down list.
One of the advantages of this is that you can easily add a form that edits a list of objects, linking text fields, etc. to the properties of one of the objects and adding a navigator that allows you to go to the next or previous line. You would not need to manually guarantee that all text fields are related to the correct object, CurrencyManager will do all this for you.
However, in your case, since you have linked the same data source to all three lists, CurrencyManager will ensure that all three select the same row. If you select a new line in one of the drop-down lists, CurrencyManager will go and fix all the others to refer to the same line.
You can fix this in various ways:
You can override the binding context for each combo box:
comboBox2nd.BindingContext = new BindingContext(); comboBox3rd.BindingContext = new BindingContext();
Note that if you are following this route, you need to do this before assigning the SelectedIndex or SelectedItem properties, otherwise the CurrencyManager will update the other two combinations before assigning new BindingContexts.
You can assign different data sources for each list:
combobox2nd.DataSource = testList.ToList(); combobox3rd.DataSource = testList.ToList();
source share