C# WPF How to modify the ComboBox's selected item's color? -
i having trouble combobox's selected item color... default, when select item combobox, it's black. how change color of item white? cannot seem modify it. what's deal?
in simplest case can write in xaml:
<combobox itemssource="{binding dropdowmitems}" foreground="red"> <combobox.itemcontainerstyle> <style targettype="{x:type comboboxitem}"> <setter property="foreground" value="black"/> </style> </combobox.itemcontainerstyle> </combobox>
in case of item template, need modify template.
Comments
Post a Comment