PivotLayout Object [Excel 2003 VBA Language Reference]

Chart
PivotLayout
PivotTable

Represents the placement of fields in a PivotChart report.

Using the PivotLayout Object

Use the PivotLayout property to return a PivotLayout object. The following example creates a list of PivotTable field names used in the first PivotChart report.

Sub ListFieldNames

   Dim objNewSheet As Worksheet 
   Dim intRow As Integer 
   Dim objPF As PivotField

   Set objNewSheet = Worksheets.Add

   intRow = 1

   For Each objPF In _
           Charts("Chart1").PivotLayout.PivotFields
           
      objNewSheet.Cells(intRow, 1).Value = objPF.Caption
      
      intRow = intRow + 1

   Next objPF
   
End Sub

Properties | Application Property | Creator Property | Parent Property | PivotTable Property

Parent Objects | Chart Object

Child Objects | PivotTable Object

See Also | PivotCache Object | PivotCell Object | PivotField Object | PivotFormula Object | PivotItem Object | PivotItemList Collection | PivotTable Object