A ListBox that displays the days of the week : ListBox « UI Controls « Silverlight






A ListBox that displays the days of the week

A ListBox that displays the days of the week
    

<UserControl x:Class='SilverlightApplication3.MainPage'
    xmlns='http://schemas.microsoft.com/winfx/2006/xaml/presentation' 
    xmlns:x='http://schemas.microsoft.com/winfx/2006/xaml'
    xmlns:d='http://schemas.microsoft.com/expression/blend/2008' 
    xmlns:mc='http://schemas.openxmlformats.org/markup-compatibility/2006' 
    mc:Ignorable='d' 
    d:DesignWidth='640' d:DesignHeight='480'>
    <Grid x:Name="LayoutRoot" Background="White">
        <ListBox x:Name="myListBox">
            <ListBox.Items>
                <ListBoxItem>
                    <TextBlock>Sunday, June 1</TextBlock>
                </ListBoxItem>
                <ListBoxItem>
                    <TextBlock>Monday, June 2</TextBlock>
                </ListBoxItem>
                <ListBoxItem>
                    <TextBlock>Tuesday, June 3</TextBlock>
                </ListBoxItem>
                <ListBoxItem>
                    <TextBlock>Wednesday, June 4</TextBlock>
                </ListBoxItem>
                <ListBoxItem>
                    <TextBlock>Thursday, June 5</TextBlock>
                </ListBoxItem>
            </ListBox.Items>
        </ListBox>
    </Grid>
</UserControl>

   
    
    
    
  








Related examples in the same category

1.ListBox data bindingListBox data binding
2.Creating a ListBoxCreating a ListBox
3.Add a simple ListBoxItem, a TextBlock, a StackPanel to ListBox
4.Put Image to ListBoxPut Image to ListBox
5.Use TextBlock as ListBox itemUse TextBlock as ListBox item