In a WPF application, I've the following in XAML:
<DockPanel Background="Black">
<ListView DockPanel.Dock="Top" ItemsSource="{Binding TestSteps}" ScrollViewer.HorizontalScrollBarVisibility="Disabled" Background="LightPink">
<ListView.View>
<GridView>
<GridViewColumn Header="" Width="Auto">
<GridViewColumn.CellTemplate>
<DataTemplate>
<fa:ImageAwesome Icon="{Binding IconType}" Foreground="{Binding Status}" SpinDuration="2" Width="10" VerticalAlignment="Center" />
</DataTemplate>
</GridViewColumn.CellTemplate>
</GridViewColumn>
<GridViewColumn Header="#" Width="Auto" DisplayMemberBinding="{Binding SerialNumber, StringFormat='00'}" />
<GridViewColumn Header="Action" Width="Auto">
<GridViewColumn.CellTemplate>
<DataTemplate>
<TextBlock Text="{Binding Action}" TextWrapping="Wrap" />
</DataTemplate>
</GridViewColumn.CellTemplate>
</GridViewColumn>
</GridView>
</ListView.View>
</ListView>
</DockPanel>
I want the 3rd column to stretch to as right as its parent let it to be. The text of this column should wrap to avoid the necessity of horizontal scrollbar.
This is what it looks like when I launch the program:
When I stretch the window horizontally, an unwanted column appears.
Instead of the appearance of the unwanted column, what I want is the 3rd column should take the available horizontal space.
How can I achieve that?