ComboBoxItem Content : ComboBox « Windows Presentation Foundation « C# / C Sharp






ComboBoxItem Content

ComboBoxItem Content
     

<Window x:Class="SimpleStyles.Window1"
  xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  Title="SimpleStyles"
  Background="#F8F8F8">
  <ScrollViewer>
    <WrapPanel>
      <HeaderedItemsControl Header="ComboBox">
        <StackPanel>
          <ComboBox Margin="8">
            <ComboBoxItem Content="First Normal Item" />
            <ComboBoxItem Content="Second Normal Item" />
            <ComboBoxItem Content="Third Normal Item" />
            <ComboBoxItem Content="Fourth Normal Item" />
            <ComboBoxItem Content="Fifth Normal Item" />
          </ComboBox>
          <ComboBox Margin="8" IsEditable="True" Text="Edit Me">
            <ComboBoxItem Content="First Normal Item" />
            <ComboBoxItem Content="Second Normal Item" />
            <ComboBoxItem Content="Third Normal Item" />
            <ComboBoxItem Content="Fourth Normal Item" />
            <ComboBoxItem Content="Fifth Normal Item" />
          </ComboBox>
        </StackPanel>
      </HeaderedItemsControl>
   
    </WrapPanel>
  </ScrollViewer>
</Window>

   
    
    
    
    
  








Related examples in the same category

1.Content in ComboBox ItemsContent in ComboBox Items
2.Set Different Font for Item for ComboBoxSet Different Font for Item for ComboBox
3.Adding Image to ComboBox Item
4.Bounded to ComboBoxBounded to ComboBox
5.Gets the currently selected ComboBoxItem when the user clicks the Button.Gets the currently selected ComboBoxItem when the user clicks the Button.
6.if the user has entered text into the ComboBox instead.if the user has entered text into the ComboBox instead.
7.Handles ComboBox SelectionChanged events.Handles ComboBox SelectionChanged events.
8.Handles ComboBoxItem Selected events.Handles ComboBoxItem Selected events.
9.View and Select Items Using a Combo BoxView and Select Items Using a Combo Box
10.Call the OnPropertyChanged method when its value changedCall the OnPropertyChanged method when its value changed