I have WPF-MVVM DataGrid. I want to use the Row Header But it is invisible. I tried to set it with RowHeaderWidth, but it doesn't have any effect. Below is my code:
<Grid DataContext="{Binding Tours}">
<DataGrid Grid.Row="0"
x:Name="tourDataGrid"
RowHeaderWidth="27"
ItemsSource="{Binding}"
AutoGenerateColumns="False"
Height="360">
What is wrong ?
Many Thanks in advance...
Try this:
<Grid DataContext="{Binding Tours}">
<DataGrid Grid.Row="0"
x:Name="tourDataGrid"
HeadersVisibility="All"
RowHeaderWidth="27"
ItemsSource="{Binding}"
AutoGenerateColumns="False"
Height="360">