Page 380 - Microsoft Office Excel 2003 Programming Inside Out
P. 380

Part 5:  Manipulating Excel Objects
                                        Microsoft Office Excel 2003 Programming Inside Out

                             The PivotItems method returns a collection of PivotItem objects. Each PivotItem object rep­
                             resents a specific value within the PivotField object.
                             You can access a PivotField object through these properties associated with the PivotTable
                             object. These properties provide a shortcut to commonly used subsets of the data.
                               ●	 The PivotFields collection contains the complete set of all PivotField objects associated
                                  with the PivotTable.
                               ●	 The HiddenFields property returns the set of PivotField objects that are not currently
                                  displayed on the PivotTable or the PivotChart.
                               ●	 The VisibleFields property returns the set of PivotField objects that are currently
                                  displayed on the PivotTable or the PivotChart.
                               ●	 The ColumnFields property returns the set of PivotField objects that are displayed as
                                  columns in a PivotTable or a PivotChart.
                               ●	 The RowFields property returns the set of PivotField objects that are displayed as rows
                                  in a PivotTable or a PivotChart.
                               ●	 The PageFields property returns the set of PivotField objects that are displayed in the
                                  page area of a PivotTable or a PivotChart.
                               ●	 The DataFields property returns the set of PivotField objects that are displayed in the
                                  data area of a PivotTable or a PivotChart.
                               ●	 The CalculatedFields collection contains the set of PivotField objects that are computed
                                  from other fields in the PivotTable.


                             Note  If there is only one PivotField in a collection, the associated property from the
                             PivotTable object will point directly to the PivotField object rather than to a PivotFields
                             collection.

             Chapter 16
                             Table 16-5 contains a list of the key properties and methods associated with the PivotField
                             object.
                             Table 16-5.  Key Properties and Methods of the PivotField Object
                             Property/Method        Description
                             Caption                Property (read-only): returns the label text for the field.
                             CurrentPage            Property: contains the current page for a page field.
                             DataRange	             Property (read-only): returns a Range object with the data
                                                    contained in the field.
                             DataType	              Property (read-only): returns the type of data from the
                                                    XlPivotFieldDataType enumeration (xlDate, xlNumber, or xlText)
                                                    that represents the field.







                354
   375   376   377   378   379   380   381   382   383   384   385