简体   繁体   中英

How to change the backcolor of combobox selected gighlighting dropdownItem in c#

When I have click on combobox, all the dropdown items will be dropped down and when the mouse hovers on an item it will highlighte in default blue color. Now I want to change the default blue color to as my wish. Please anybod help. Thank you

如果使用的是WinForms,则可以使用自定义ComboBox或Microsoft ComboBox上的DrawItem事件来实现,例如,在WPF中,您可以覆盖XAML中的Color。

You can't override this style. Check following questions for explanation:

However you can try to simulate dropdown by creating it with js and provide any style you want. Check links to get example:

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM