# Other .NET Programming > Windows Presentation Foundation (WPF) & XAML forum >  How to change foreground color of combobox by choose different value in wpf C#

## sanjay.vaniya

bellow snipet code

xaml code:

<ComboBox x:Name="cb" SelectionChanged="ComboBox_SelectionChanged" Width="100" Height="25" IsEditable="True" Text="HelloWorld">
            <ComboBoxItem Content="Coffie"></ComboBoxItem>
            <ComboBoxItem Content="Tea"></ComboBoxItem>
            <ComboBoxItem Content="Orange Juice"></ComboBoxItem>
            <ComboBoxItem Content="Milk"></ComboBoxItem>
            <ComboBoxItem Content="Iced Tea"></ComboBoxItem>
            <ComboBoxItem Content="Mango Shake"></ComboBoxItem>
</ComboBox>

code behind:

private void ComboBox_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            if (__________ == "Milk")
            {
                code //
            }

        }

----------

