Hello,
I have a gridview with the set of columns shown below. The first two columns have AggregateFunctions (sum). I have a third column which should be the the result of dividing VacantSpaceRentableArea by TotalArea. I need this to be inside a custom aggregate function as the totals need to be recalculated as users group data by different columns.
I have seen the examples of custom aggregate functions but all the examples I have seen refer only one column. Is there any way to implement a custom aggregate function that references more than one column?
Thanks.
Edwin
<telerik:GridViewDataColumn Header="Vac. % Based on Rentable Area" DataMemberBinding="{Binding VacancyPctOfRentableArea}" IsReadOnly="True" DataFormatString="P2">
I have a gridview with the set of columns shown below. The first two columns have AggregateFunctions (sum). I have a third column which should be the the result of dividing VacantSpaceRentableArea by TotalArea. I need this to be inside a custom aggregate function as the totals need to be recalculated as users group data by different columns.
I have seen the examples of custom aggregate functions but all the examples I have seen refer only one column. Is there any way to implement a custom aggregate function that references more than one column?
Thanks.
Edwin
<
telerik:GridViewDataColumn Header="Total Area" DataMemberBinding="{Binding TotalArea}" IsReadOnly="True" DataFormatString="N0">
<telerik:GridViewDataColumn.AggregateFunctions>
<telerik:SumFunction Caption="Total Area: "/>
</telerik:GridViewDataColumn.AggregateFunctions>
</telerik:GridViewDataColumn>
<telerik:GridViewDataColumn Header="Vac. Space Rentable Area" DataMemberBinding="{Binding VacantSpaceRentableArea}" IsReadOnly="True" DataFormatString="N0">
<telerik:GridViewDataColumn.AggregateFunctions>
<telerik:SumFunction Caption="Total Rentable Area: "/>
</telerik:GridViewDataColumn.AggregateFunctions>
</telerik:GridViewDataColumn>
<telerik:GridViewDataColumn Header="Vac. % Based on Rentable Area" DataMemberBinding="{Binding VacancyPctOfRentableArea}" IsReadOnly="True" DataFormatString="P2">
<!-- Need custom aggregate function here that will calculate VacantSpaceRentableArea / TotalArea -->
</telerik:GridViewDataColumn>