Edit
Wrote a small demo app - Download
First approach - Bind to DataGrid.SelectedItem
Place a property in the ViewModel called SelectedProgr
then in the XAML bind the DataGrid's SelectedItem property to it:
<DataGrid ItemsSource="{Binding Path=Progr}"
...
...
SelectedItem="{Binding Path=SelectedProgr, Mode=TwoWay}"/>
Afterwards create a custom view that depends on the SelectedProgr
for example:
<Label Text={Binding Path=SelectedProgr}>
Second approach - Using RowDetailsTemplate
Example from wpftutorial.net:
<DataGrid ItemsSource="{Binding Progr}">
<DataGrid.Columns>
<DataGridTextColumn Header="SerialNumber" Binding="{Binding Path=SerialNumber}" Width="2*"></DataGridTextColumn>
<DataGridTextColumn Header="FirstName" Binding="{Binding Path=FirstName}" Width="2*"></DataGridTextColumn>
<DataGridTextColumn Header="LastName" Binding="{Binding Path=LastName}" Width="3*"></DataGridTextColumn>
</DataGrid.Columns>
<DataGrid.RowDetailsTemplate>
<DataTemplate>
<!-- Put here your custom view -->
<Image Height="100" Source="{Binding Image}" />
</DataTemplate>
</DataGrid.RowDetailsTemplate>
</DataGrid>