【发布时间】:2014-12-11 07:02:08
【问题描述】:
我正在尝试显示与列标题对齐的组总计,但未能成功。通过设置以下属性 ShowGroupHeaderColumnAggregates 和 ShowHeaderAggregates ,您应该可以在这里Telerik Grouping Documentation
这是我正在使用的 XAML - 我做错了什么还是它不起作用?属性设置器似乎没有效果。
<Window x:Class="GridViewTest.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="MainWindow" Height="350" Width="525"
xmlns:t="http://schemas.telerik.com/2008/xaml/presentation">
<Window.Resources>
<Style TargetType="t:GroupHeaderRow">
<Setter Property="ShowGroupHeaderColumnAggregates" Value="True" />
<Setter Property="ShowHeaderAggregates" Value="False" />
</Style>
</Window.Resources>
<Grid>
<t:RadGridView ItemsSource="{Binding Path=Records}" SelectionMode="Extended">
<t:RadGridView.GroupDescriptors>
<t:GroupDescriptor Member="Column1" SortDirection="Ascending">
<t:GroupDescriptor.AggregateFunctions>
<t:CountFunction Caption="Entries count: " />
<t:FirstFunction Caption="First entry: " />
</t:GroupDescriptor.AggregateFunctions>
</t:GroupDescriptor>
</t:RadGridView.GroupDescriptors>
</t:RadGridView>
</Grid>
【问题讨论】:
-
你解决了吗?
标签: wpf xaml telerik radgridview