views:

433

answers:

0

Hi,
I have a set of ComboBoxes. I want to use them mostly like short data-entry TextBoxes, so I have them set to
AutoCompleteMode = SuggestAppend
AutoCompleteSource = ListItems
DropDownStyle = DropDown

What I want to do is to have each ComboBox have a common DataSource (the My.Settings StringCollection) whereby any String added to or removed from the DataSource is added to or removed from the DataSource of each ComboBox.

Through various experiments with BindingSources and DataBindings and the like, I have managed to get the ComboBoxes either all having the same DataSource, but all showing the same text, or getting them all to have the same DataSource, but not being able to reflect changes to the DataSource between ComboBoxes to various new and wonderful ways of throwing exceptions.

So, basically, what I want is for all the ComboBoxes to use a StringCollection as their DataSource, to propagate changes to the DataSource through all the ComboBoxes, but for the choice of SelectedItem to be independent between all the ComboBoxes.

Any ideas?

Thanks.