<!-- GroupHeaderStyle -->
<Style x:Key="GroupHeaderStyle" TargetType="{x:Type GroupItem}">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type GroupItem}">
<Expander IsExpanded="False" Margin="15,0,0,0">
<Expander.Header>
<StackPanel Orientation="Horizontal">
<TextBlock Text="{Binding ????????????}"/>
<TextBlock Text="-->"/>
<TextBlock Text="{Binding Name}"/>
</StackPanel>
</Expander.Header>
<ItemsPresenter />
</Expander>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
In the above code I wish to display the property name by which it is grouped. E.g. Gender --> Boy ; Gender --> Girl.
public class Test
{
string gender;
public string Gender
{
get { return gender; }
set { gender = value; }
}
}
What should i provide for ???????????? in the above xaml?
Also, please let me know if there is any good book or link which explains the internal details of grouping in ListCollectionView
.