Click here to Skip to main content
Sign Up to vote bad
good
See more: WPF
how to change the color of drop down button of combo box in wpf?the combo box is appearing blue color default in windowxp. please do the needful to me .
Posted 29-Jan-13 2:42am


1 solution

<Style TargetType="{x:Type ComboBoxItem}">
            <Setter Property="Background">
                <Setter.Value>
                    <LinearGradientBrush EndPoint="0,1" StartPoint="0,0">
                        <GradientStop Color="#FF3A60AD" Offset="0.528"/>
                        <GradientStop Color="#FF6A85D8" Offset="0.01"/>
                        <GradientStop Color="#FF3464C4" Offset="1"/>
                        <GradientStop Color="#FF202E7E" Offset="1"/>
                    </LinearGradientBrush>
                </Setter.Value>
            </Setter>
        </Style>
 
You can add a style to target All comboBox Item, which is what is given in my example. Alternatively, you can individually brush each item by modifying each items individual properties.
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Your Filters
Interested
Ignored
     
0 Prasad_Kulkarni 407
1 Sergey Alexandrovich Kryukov 340
2 _Amy 331
3 Christian Graus 268
4 OriginalGriff 235
0 Sergey Alexandrovich Kryukov 6,649
1 Prasad_Kulkarni 3,281
2 _Amy 3,065
3 OriginalGriff 2,989
4 CPallini 2,696


Advertise | Privacy | Mobile
Web04 | 2.6.130617.1 | Last Updated 29 Jan 2013
Copyright © CodeProject, 1999-2013
All Rights Reserved. Terms of Use
Layout: fixed | fluid