Macro Sheets Only
Pivots a field within a PivotTable.
Syntax
PIVOT.FIELD(name, pivot_field_name, orientation, position)
Name is the name of the PivotTable in which the user wants to pivot fields. If name is omitted, Microsoft Excel will use the PivotTable containing the active cell.
Pivot_field_name is the name of the field which the user wishes to pivot to another part of the PivotTable. This argument is given as a text constant or a reference to a text constant. If field_name is omitted, Microsoft Excel uses the field containing the active cell.
Orientation is an integer representing the destination of the field which is being pivoted. If this argument is omitted, then the orientation remains unchanged. The integers refer to orientations as follows:
Value Orientation
0 Hidden
1 Row
2 Column
3 Page
4 Data
Position is an integer representing where in the orientation the fields will be positioned. Position 1 is the leftmost header position in the row header and the topmost position in the column header. This argument is ignored if orientation is set to 0. If the position argument is omitted, it will default to the last position in the field.
Remarks
Related Functions
PIVOT.ADD.DATA Adds a field to a PivotTable as a Data Field
PIVOT.ADD.FIELDS Adds fields to a PivotTable
PIVOT.FIELD.GROUP Creates groups within a PivotTable
PIVOT.FIELD.PROPERTIES Changes the properties of a field inside a PivotTable
PIVOT.FIELD.UNGROUP Ungroups all selected groups within a PivotTable
PIVOT.ITEM Moves an item within a PivotTable
PIVOT.ITEM.PROPERTIES Changes the properties of an item within a header field
PIVOT.REFRESH Refreshes a PivotTable
PIVOT.SHOW.PAGES Creates new sheets in the workbook containing the active cell
PIVOT.TABLE.WIZARD Creates an empty PivotTable
List of Command-Equivalent Functions