Category / Section
How to select the item programmatically in winforms MultiSelectionComboBox?
1 min read
You can select the item programmatically in MultiSelectionComboBox control by using SelectedItem or SelectedItems property.
Refer the below code for your reference.
C#
// Using SelectedItem property to add item programmatically. multiSelectionComboBox1.SelectedItem = multiSelectionComboBox1.Items[4]; // Using SelectedItems property to add item programmatically. // multiSelectionComboBox1.SelectedItems.Add(multiSelectionComboBox1.Items[4]);
You can also select the item in MultiSelectionComboBox control by using SelectedIndex property.
Refer the below code for your reference.
C#
//Select the item in control multiSelectionComboBox1.SelectedIndex = 4;