officefileapi-devexpress-dot-spreadsheet-dot-pivotviewoptions-b2839826.md
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.v25.2.Core.dll
NuGet Package : DevExpress.Spreadsheet.Core
string GrandTotalCaption { get; set; }
Property GrandTotalCaption As String
| Type | Description |
|---|---|
| String |
A String value that specifies the text label to be displayed in the grand total column and grand total row.
|
You can access this nested property as listed below:
| Object Type | Path to GrandTotalCaption |
|---|---|
| PivotTable |
.View .GrandTotalCaption
|
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";
pivotTable.View.GrandTotalCaption = "Total Sales"
The image below illustrates the result of code execution.
See Also