ListBox Control Sample

Inheritance of System.Windows.Controls.ListBox :

System.Object
 System.Windows.Threading.DispatcherObject
  System.Windows.DependencyObject
   System.Windows.Media.Visual
    System.Windows.UIElement
     System.Windows.FrameworkElement
      System.Windows.Controls.Control
       System.Windows.Controls.ItemsControl
        System.Windows.Controls.Primitives.Selector
         System.Windows.Controls.ListBox
          System.Windows.Controls.ListView
  ListBox with 9 ListBoxItems.
Item 2 is selected and the SelectionChanged-event fires.

SelectionMode="Single": Just one item can be selected at once = default.
SelectionMode="Multiple": Two or more can be selected.
SelectionMode="Extended": A range can be selected holding down the Ctrl-key.
<Page xmlns  ="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      Width="100" Height ="200">
 <ListBox>
  <ListBoxItem Content="Item 1"/>
  <ListBoxItem Content="Item 2"/>
  <ListBoxItem Content="Item 3"/>
  <ListBoxItem><Image Source="http://www.miszalok.de/Images/Madonna32.bmp"/></ListBoxItem>
  <ListBoxItem Content="Item 5"/>
  <ListBoxItem><Button Content="I'm a button"/></ListBoxItem>
  <ListBoxItem Content="Item 7"/>
  <ListBoxItem><Ellipse Width="32" Height="32" Stroke="Black"/></ListBoxItem>
  <ListBoxItem Content="Item 9"/>
 </ListBox>
</Page>

When you are in the Internet Explorer run ListBox.xaml and click its items !