ComboBox case-sensitive drop-down list

I have a DropDown ComboBox control that contains the elements "AAA", "Aaa", "Aa +", etc.

The problem is that if I type Aaa, the "AAA" item is highlighted as the selected, not "Aaa". I assume that combobox uses FindString to search for SelectedItem - so the search result is equivalent to the first matching item in a case-insensitive .StartsWith string.

What do I need to change to override this behavior?

I need to be able to enter ComboBox.

Is there a method in winforms that I could override or some property similar to the WPF IsTextSearchCaseSensitive property from sll response?

+7
source share
2 answers

If you are using WPF, just set the IsTextSearchCaseSensitive parameter to true.

+3
source

You can use this:

myComboBox.SelectedIndex = myComboBox.Items.IndexOf("CaseSensitiveTextHere"); 
-one
source

All Articles