Skip to content

Latest commit

 

History

History
48 lines (29 loc) · 1.14 KB

Excel.Worksheet.PivotTables.md

File metadata and controls

48 lines (29 loc) · 1.14 KB
title keywords f1_keywords api_name ms.assetid ms.date ms.localizationpriority
Worksheet.PivotTables method (Excel)
vbaxl10.chm175118
vbaxl10.chm175118
Excel.Worksheet.PivotTables
b60944cd-827d-15dc-d49e-c739c237de15
05/30/2019
medium

Worksheet.PivotTables method (Excel)

Returns an object that represents either a single PivotTable report (a PivotTable object) or a collection of all the PivotTable reports (a PivotTables object) on a worksheet. Read-only.

Syntax

expression.PivotTables (Index)

expression A variable that represents a Worksheet object.

Parameters

Name Required/Optional Data type Description
Index Optional Variant The name or number of the report.

Return value

Object

Example

This example sets the Sum of 1994 field in the first PivotTable report on the active sheet to use the SUM function.

ActiveSheet.PivotTables("PivotTable1"). _ 
 PivotFields("Sum of 1994").Function = xlSum

[!includeSupport and feedback]