Back to Devexpress

CustomizePivotCellEventArgs.ExportArea Property

windowsforms-devexpress-dot-xtrapivotgrid-dot-customizepivotcelleventargs-a76d3026.md

latest3.0 KB
Original Source

CustomizePivotCellEventArgs.ExportArea Property

Gets the PivotGrid field area to which the current cell corresponds.

Namespace : DevExpress.XtraPivotGrid

Assembly : DevExpress.XtraPivotGrid.v25.2.dll

NuGet Package : DevExpress.Win.PivotGrid

Declaration

csharp
public PivotExportArea ExportArea { get; }
vb
Public ReadOnly Property ExportArea As PivotExportArea

Property Value

TypeDescription
PivotExportArea

The PivotGrid field area of the current cell in the export document.

|

Available values:

NameDescription
None

A cell does not correspond to any Pivot Grid’s area.

| | Column |

A cell corresponds to the Pivot Grid’s column area.

| | Row |

A cell corresponds to the Pivot Grid’s row area.

| | Data |

A cell corresponds to the Pivot Grid’s data area.

|

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the ExportArea property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

winforms-pivotgrid--customize-cells-in-the-exported-excel-document/CS/WinPivotExportCustomizeCell/Form1.cs#L39

csharp
void exportOptions_CustomizeCell(CustomizePivotCellEventArgs e) {
    if (e.ExportArea == PivotExportArea.Data) {
        e.Formatting.BackColor = Color.Azure;

winforms-pivotgrid--customize-cells-in-the-exported-excel-document/VB/WinPivotExportCustomizeCell/Form1.vb#L41

vb
Private Sub exportOptions_CustomizeCell(ByVal e As CustomizePivotCellEventArgs)
    If e.ExportArea = PivotExportArea.Data Then
        e.Formatting.BackColor = Color.Azure

See Also

CustomizePivotCellEventArgs Class

CustomizePivotCellEventArgs Members

DevExpress.XtraPivotGrid Namespace