Added this since it is a significant addition to
ListView
.
ListView
supports complex cell content. Have a sample here:
<window x:class="WpfApplication1.MainWindow" xmlns:x="#unknown">
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="MainWindow" Height="350" Width="525">
<grid>
<listview>
<listview.view>
<gridview>
<gridviewcolumn width="120" header="Date">
<gridviewcolumn.celltemplate>
<datatemplate>
<stackpanel>
<checkbox />
</stackpanel>
</datatemplate>
</gridviewcolumn.celltemplate>
</gridviewcolumn>
<gridviewcolumn width="120" header="Day Of Week">
DisplayMemberBinding="{Binding DayOfWeek}" />
<gridviewcolumn width="120" header="Year">
DisplayMemberBinding="{Binding Year}" />
</gridviewcolumn></gridviewcolumn></gridview>
</listview.view>
</listview>
</grid>
</window>
As you can see the
ListView
GridViewColumn
suports a template content. Here I only put a
CheckBox
inside, but since I put this in a
StackPanel
, easily add more inside the
Stackpanel
(make it a Grid if that is better). Depends on the content you want. May or may not help.