Skip to main content
Row

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

PivotViewOptions.GrandTotalCaption Property

Gets or sets the text to be displayed in grand totals for rows and columns in a pivot table.

Namespace: DevExpress.Spreadsheet

Assembly: DevExpress.Spreadsheet.v24.2.Core.dll

NuGet Package: DevExpress.Spreadsheet.Core

#Declaration

string GrandTotalCaption { get; set; }

#Property Value

Type Description
String

A String value that specifies the text label to be displayed in the grand total column and grand total row.

#Property Paths

You can access this nested property as listed below:

Object Type Path to GrandTotalCaption
PivotTable
.View .GrandTotalCaption

#Remarks

Use the GrandTotalCaption property to specify a custom label for grand totals in a PivotTable report. By default, the “Grand Total” string is used as the label for both the grand total column and grand total row.

To display or hide grand totals for rows and columns in a PivotTable report, use the PivotLayout.ShowRowGrandTotals and PivotLayout.ShowColumnGrandTotals properties.

pivotTable.View.GrandTotalCaption = "Total Sales";

The image below illustrates the result of code execution.

SpreadsheetPivotTable_GrandTotalCaption

See Also