PivotCache Object

Description

Represents the memory cache for a PivotTable. The PivotCache object is a member of the PivotCaches collection.

Using the PivotCache Object

Use the PivotCache method to return a PivotCache object for a PivotTable (each PivotTable has only one cache). The following example causes PivotTable one to refresh itself whenever its file is opened.

Worksheets(1).PivotTables(1).PivotCache.RefreshOnFileOpen = True
Use PivotCaches(index), where index is the cache number, to return a single PivotCache object from the PivotCaches collection for a workbook. The following example refreshes cache one.

ActiveWorkbook.PivotCaches(1).Refresh
Properties

Application property, BackgroundQuery property, Connection property, Creator property, EnableRefresh property, Index property, MemoryUsed property, OptimizeCache property, Parent property, RecordCount property, RefreshDate property, RefreshName property, RefreshOnFileOpen property, SavePassword property, SourceData property, Sql property.

Methods

Refresh method.