我有一个WPF数据网格。我这样将数据绑定到网格。
<DataGrid Name="DgChips"
Style="{StaticResource DataGridStyle}"
Grid.Row="0"
ColumnHeaderStyle="{StaticResource DataGridColumnHeader}"
AutoGenerateColumns="False"
xmlns:s="clr-namespace:System;assembly=mscorlib">
<DataGrid.Resources>
<s:String x:Key="format">{0:N0}</s:String>
<s:String x:Key="formatDoller">{0:C0}</s:String>
</DataGrid.Resources>
<DataGrid.Columns>
<DataGridTextColumn
Header="ChipSet Code"
Binding="{Binding sChipSetCode}"
CellStyle="{StaticResource DataGridCellStyleCenter}"
/>
<DataGridTextColumn
Header="Denom"
Binding="{Binding iChipDenomination, StringFormat={StaticResource formatDoller}}"
CellStyle="{StaticResource DataGridCellStyleRight}"/>
<DataGridTextColumn
Header="Count"
Binding="{Binding iChipsCount, StringFormat={StaticResource format}}"
CellStyle="{StaticResource DataGridCellStyleRight}"/>
<DataGridTextColumn
Header="Value"
Binding="{Binding iChipsValue, StringFormat={StaticResource formatDoller}}"
CellStyle="{StaticResource DataGridCellStyleRight}"/>
</DataGrid.Columns>
</DataGrid>
现在,我想对“ sChipSetCode”中的数据进行分组。我该怎么办?