<Window x:Class="DataBinding.NavigateCollection"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    Title="NavigateCollection" Height="367" Width="422"
        xmlns:local="clr-namespace:DataBinding"
    >
 
  <Grid Margin="10">
      <Grid.RowDefinitions>
        <RowDefinition Height="Auto"></RowDefinition>
        <RowDefinition Height="*"></RowDefinition>
        <RowDefinition Height="Auto"></RowDefinition>
      </Grid.RowDefinitions>
    
      <ComboBox Name="lstProducts" DisplayMemberPath="ModelName" Text="{Binding Path=ModelName}"
                IsSynchronizedWithCurrentItem="True"
                SelectionChanged="lstProducts_SelectionChanged" ></ComboBox>

      <Border Grid.Row="1" Padding="5" Margin="0,5,0,5" Background="LightSteelBlue">
        <Grid>
          <Grid.ColumnDefinitions>
            <ColumnDefinition Width="Auto"></ColumnDefinition>
            <ColumnDefinition></ColumnDefinition>
          </Grid.ColumnDefinitions>
          <Grid.RowDefinitions>
            <RowDefinition Height="Auto"></RowDefinition>
            <RowDefinition Height="Auto"></RowDefinition>
            <RowDefinition Height="Auto"></RowDefinition>
            <RowDefinition Height="Auto"></RowDefinition>
            <RowDefinition Height="*"></RowDefinition>
          </Grid.RowDefinitions>

          <TextBlock Margin="7">Model Number:</TextBlock>
          <TextBox Margin="5" Grid.Column="1" Text="{Binding Path=ModelNumber}"></TextBox>
          <TextBlock Margin="7" Grid.Row="1">Model Name:</TextBlock>
          <TextBox Margin="5" Grid.Row="1" Grid.Column="1" Text="{Binding Path=ModelName}"></TextBox>
          <TextBlock Margin="7" Grid.Row="2">Unit Cost:</TextBlock>
          <TextBox Margin="5" Grid.Row="2" Grid.Column="1" Text="{Binding Path=UnitCost,StringFormat={}{0:C}}"></TextBox>
          <TextBlock Margin="7,7,7,0" Grid.Row="3">Description:</TextBlock>
          <TextBox Margin="7" Grid.Row="4" Grid.Column="0" Grid.ColumnSpan="2" 
                   TextWrapping="Wrap" VerticalScrollBarVisibility="Visible" Text="{Binding Path=Description}"></TextBox>
        </Grid>        
      </Border>

    <Grid Grid.Row="2">
      <StackPanel Orientation="Horizontal">
        <Button Name="cmdPrev" Click="cmdPrev_Click">&lt;</Button>
        <TextBlock Margin="5,0,5,0" Name="lblPosition" VerticalAlignment="Center"></TextBlock>
        <Button Name="cmdNext" Click="cmdNext_Click">&gt;</Button>
      </StackPanel>
    </Grid>
    </Grid>
</Window>
