Class PivotCell (Excel VBA)

The class PivotCell represents a cell in a PivotTable report.

The classes PivotValueCell, Range and ValueChange. give access to class PivotCell

Member in collection

Item

To use a PivotCell class variable it first needs to be instantiated, for example

Dim pvtlcel as PivotCell
Set pvtlcel = ActiveCell.PivotCell

The following procedures can be used to set variables of type PivotCell: PivotLineCells.Item, PivotValueCell.PivotCell, Range.PivotCell and ValueChange.PivotCell.

For Each

Here is an example of processing the PivotCell items in a collection.

Dim pvtlcelPivotLineCell As PivotCell
For Each pvtlcelPivotLineCell In Application.PivotLineCells
	
Next pvtlcelPivotLineCell

AllocateChange - Performs a writeback operation on the specified cell in a PivotTable report based on an OLAP data source.

DiscardChange - Discards changes to the specified cell in a PivotTable report.

Properties

PivotLineCells.Item (Default member) - Returns a specific element of the PivotLineCells collection object by its position in the collection.

CellChanged returns whether a PivotTable value cell has been edited or recalculated since the PivotTable report was created or the last commit operation was performed.

ColumnItems returns a PivotItemList collection that corresponds to the items on the column axis that represent the selected range.

CustomSubtotalFunction returns the custom subtotal function field setting of a PivotCell object.

DataField returns a PivotField object that corresponds to the selected data field.

DataSourceValue returns the value last retrieved from the data source for edited cells in a PivotTable report.

MDX returns a tuple that provides the full MDX coordinates of the specified value cell in a PivotTable with an OLAP data source.

PivotCellType returns one of the XlPivotCellType constants that identifies the PivotTable entity that the cell corresponds to.

PivotColumnLine returns the PivotLine object on a column for a specific PivotCell object.

PivotField returns a PivotField object that represents the PivotTable field containing the upper-left corner of the specified range.

PivotItem returns a PivotItem object that represents the PivotTable item containing the upper-left corner of the specified range.

PivotRowLine returns the PivotLine object on a row for a specific PivotCell object.

PivotTable returns a PivotTable object that represents the PivotTable report associated with the PivotCell.

Range returns a Range object that represents the range that the specified PivotCell applies to.

RowItems returns a PivotItemList collection that corresponds to the items on the category axis that represent the selected cell.

ServerActions represents a collection of actions consisting of OLAP-defined actions that can be executed. The actions are specific to PivotTables existing at a worksheet-level.

PivotLineCells.Count returns the number of items in the PivotLineCells collection.

PivotLineCells.Full when True, all of the PivotLineCells in the PivotLine (including those that are hidden in compact form) are retrieved.

Actions - A collection of all Action objects for the specified series.

PivotField - Represents a field in a PivotTable report.

PivotItem - Represents an item in a PivotTable field.

PivotItemList - A collection of all the PivotItem objects in the specified PivotTable.

PivotLine - A PivotLine object is a line of rows or columns in an Excel PivotTable.

PivotTable - Represents a PivotTable report on a worksheet.

Range - Represents a cell, a row, a column, a selection of cells containing one or more contiguous blocks of cells, or a 3D range.