This is a migrated thread and some comments may be shown as answers.

Compare cell value to his grand total

1 Answer 144 Views
PivotGrid
This is a migrated thread and some comments may be shown as answers.
karn
Top achievements
Rank 1
karn asked on 08 Aug 2018, 03:39 PM

Hi,

how i can compare cell value to his grand total (for after change color).

I try in CellDataBound, but how access to the grand total ?

 

 

 

 

1 Answer, 1 is accepted

Sort by
0
Eyup
Telerik team
answered on 13 Aug 2018, 02:03 PM
Hi Karn,

Generally, please note the RadPivotGrid control does not provide custom row(item)-based logic execution and I am afraid it is not possible to get the grand total value or any of the cell values in order to calculate the final sum in the Individual Totals section. The item-based calculation logic is the specialty of the RadGrid control:
https://www.telerik.com/forums/template-column-for-pivot-grid#ro_LCNv1N0GIQ46Jj0413w
https://www.telerik.com/forums/hyperlink-pivotgrid#64k0GoVm1UCl7C3xNlNcIA

Therefore, I am afraid this requirement is not supported with RadPivotGrid. RadGrid has something similar to what you are trying to achieve, but it is a different control:
https://demos.telerik.com/aspnet-ajax/grid/examples/functionality/grouping/group-footers/defaultcs.aspx

You can check the following resource for additional info about the RadPivotGrid purpose and functionality:
https://www.telerik.com/blogs/aspnet-pivot-table-made-easy

Generally, you can use the following property for data:
<telerik:PivotGridAggregateField ... Aggregate="Average">


RadPivotGrid offers some neat calculation options, like the Calculation Expression (check Average Price) and the custom CalculatedItem (check Forecast for 1999):
http://demos.telerik.com/aspnet-ajax/pivotgrid/examples/calculations/defaultcs.aspx

A detailed explanation is provided here:
https://docs.telerik.com/devtools/aspnet-ajax/controls/pivotgrid/fields/custom-data-calculations

To clarify this further, I am sending a sample RadPivotGrid web site.

I hope this will prove helpful.


Regards,
Eyup
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Tags
PivotGrid
Asked by
karn
Top achievements
Rank 1
Answers by
Eyup
Telerik team
Share this question
or