List<Customer> _customers = getCustomers().ToList();
BindingSource bsCustomers = new BindingSource();
bsCustomers.DataSource = _customers;
comboBox.DataSource = bsCustomers.DataSource;
comboBox.DisplayMember = "name";
comboBox.ValueMember = "id";
Now how do I set the combobox’s Item to something other than the first in the list?
Tried
comboBox.SelectedItem = someCustomer;
…and lots of other stuff but no luck so far…
You should do
or
or