PivotTable
PivotTable class
Summary description for PivotTable.
Properties
| Name | Type | Description |
|---|---|---|
| PivotCache | PivotCache | |
| IsExcel2003Compatible | boolean | Specifies whether the PivotTable is compatible for Excel2003 when refreshing PivotTable, if true, a string must be less |
| RefreshedByWho | String | Gets the name of the last user who refreshed this PivotTable |
| RefreshDate | DateTime | Gets the last date time when the PivotTable was refreshed. |
| PivotTableStyle | TableStyle | |
| PivotTableStyleName | String | Gets and sets the pivottable style name. |
| PivotTableStyleType | int | Gets and sets the built-in pivot table style. The value of the property is PivotTableStyleType integer constant. |
| ColumnFields | PivotFieldCollection | Returns a PivotFields object that are currently shown as column fields. |
| RowFields | PivotFieldCollection | Returns a PivotFields object that are currently shown as row fields. |
| PageFields | PivotFieldCollection | Returns a PivotFields object that are currently shown as page fields. |
| DataFields | PivotFieldCollection | Gets a PivotField object that represents all the data fields in a PivotTable. Read-only.It would be init only when there |
| DataField | PivotField | Gets a PivotField object that represents all the data fields in a PivotTable. Read-only. It would only be created when t |
| ValuesField | PivotField | |
| BaseFields | PivotFieldCollection | Returns all base pivot fields in the PivotTable. |
| PivotFilters | PivotFilterCollection | Returns a list of pivot filters. |
| TopRightArea | CellArea | |
| FilterArea | CellArea | |
| ColumnRange | CellArea | Returns a CellArea object that represents the range that contains the column area in the PivotTable report. Read-only. |
| RowRange | CellArea | Returns a CellArea object that represents the range that contains the row area in the PivotTable report. Read-only. |
| DataBodyRange | CellArea | Returns a CellArea object that represents the range that contains the data area in the list between the header row and t |
| TableRange1 | CellArea | Returns a CellArea object that represents the range containing the entire PivotTable report, but doesn’t include page fi |
| TableRange2 | CellArea | Returns a CellArea object that represents the range containing the entire PivotTable report, includes page fields. Read- |
| IsGridDropZones | boolean | Indicates whether the PivotTable report displays classic pivottable layout. (enables dragging fields in the grid) |
| ShowColumnGrandTotals | boolean | |
| ShowRowGrandTotals | boolean | |
| ColumnGrand | boolean | Indicates whether the PivotTable report shows grand totals for columns. |
| RowGrand | boolean | Indicates whether the PivotTable report shows grand totals for rows. |
| DisplayNullString | boolean | Indicates whether the PivotTable report displays a custom string if the value is null. |
| NullString | String | Gets the string displayed in cells that contain null values when the DisplayNullString property is true.The default valu |
| DisplayErrorString | boolean | Indicates whether the PivotTable report displays a custom string in cells that contain errors. |
| DataFieldHeaderName | String | Gets and sets the name of the value area field header in the PivotTable. |
| ErrorString | String | Gets the string displayed in cells that contain errors when the DisplayErrorString property is true.The default value is |
| IsAutoFormat | boolean | Indicates whether the PivotTable report is automatically formatted. Checkbox “autoformat table " which is in pivottable |
| AutofitColumnWidthOnUpdate | boolean | Indicates whether autofitting column width on update |
| AutoFormatType | int | Gets and sets the auto format type of PivotTable. The value of the property is PivotTableAutoFormatType integer constant |
| HasBlankRows | boolean | Indicates whether to add blank rows. This property only applies for the PivotTable auto format types which needs to add |
| MergeLabels | boolean | True if the specified PivotTable report’s outer-row item, column item, subtotal, and grand total labels use merged cells |
| PreserveFormatting | boolean | Indicates whether formatting is preserved when the PivotTable is refreshed or recalculated. |
| ShowDrill | boolean | Gets and sets whether showing expand/collapse buttons. |
| EnableDrilldown | boolean | Gets whether drilldown is enabled. |
| EnableFieldDialog | boolean | Indicates whether the PivotTable Field dialog box is available when the user double-clicks the PivotTable field. |
| EnableFieldList | boolean | Gets whether enable the field list for the PivotTable. |
| EnableWizard | boolean | Indicates whether the PivotTable Wizard is available. |
| SubtotalHiddenPageItems | boolean | Indicates whether hidden page field items in the PivotTable report are included in row and column subtotals, block total |
| GrandTotalName | String | Returns the text string label that is displayed in the grand total column or row heading. The default value is the strin |
| ManualUpdate | boolean | Indicates whether the PivotTable report is recalculated only at the user’s request. |
| IsMultipleFieldFilters | boolean | Specifies a boolean value that indicates whether the fields of a PivotTable can have multiple filters set on them. |
| AllowMultipleFiltersPerField | boolean | |
| MissingItemsLimit | int | Specifies a boolean value that indicates whether the fields of a PivotTable can have multiple filters set on them. The v |
| EnableDataValueEditing | boolean | Specifies a boolean value that indicates whether the user is allowed to edit the cells in the data area of the pivottabl |
| ShowDataTips | boolean | Specifies a boolean value that indicates whether tooltips should be displayed for PivotTable data cells. |
| ShowMemberPropertyTips | boolean | Specifies a boolean value that indicates whether member property information should be omitted from PivotTable tooltips. |
| ShowValuesRow | boolean | Specifies a boolean value that indicates whether show values row. show the values row |
| ShowEmptyCol | boolean | Specifies a boolean value that indicates whether to include empty columns in the table |
| ShowEmptyRow | boolean | Specifies a boolean value that indicates whether to include empty rows in the table. |
| FieldListSortAscending | boolean | Indicates whether fields in the PivotTable are sorted in non-default order in the field list. |
| PrintDrill | boolean | Specifies a boolean value that indicates whether drill indicators should be printed. print expand/collapse buttons when |
| AltTextTitle | String | Gets the title of the altertext |
| AltTextDescription | String | Gets the description of the alt text |
| Name | String | Gets the name of the PivotTable |
| ColumnHeaderCaption | String | Gets the Column Header Caption of the PivotTable. |
| Indent | int | Specifies the indentation increment for compact axis and can be used to set the Report Layout to Compact Form. |
| RowHeaderCaption | String | Gets the Row Header Caption of the PivotTable. |
| ShowRowHeaderCaption | boolean | Indicates whether row header caption is shown in the PivotTable report Indicates whether Display field captions and filt |
| CustomListSort | boolean | Indicates whether consider built-in custom list when sort data |
| PivotFormatConditions | PivotFormatConditionCollection | Gets the Format Conditions of the pivot table. |
| ConditionalFormats | PivotConditionalFormatCollection | |
| PageFieldOrder | int | Gets the order in which page fields are added to the PivotTable report’s layout. The value of the property is PrintOrder |
| PageFieldWrapCount | int | Gets the number of page fields in each column or row in the PivotTable report. |
| Tag | String | Gets a string saved with the PivotTable report. |
| SaveData | boolean | Indicates whether data for the PivotTable report is saved with the workbook. |
| RefreshDataOnOpeningFile | boolean | Indicates whether Refresh Data when Opening File. |
| RefreshDataFlag | boolean | Indicates whether Refreshing Data or not. |
| SourceType | byte | The value of the property is PivotTableSourceType integer constant. |
| ExternalConnectionDataSource | ExternalConnection | Gets the external connection data source. |
| DataSource | String[] | Gets and sets the data source of the pivot table. |
| PivotFormats | PivotTableFormatCollection | Gets the collection of formats applied to PivotTable. |
| ItemPrintTitles | boolean | Indicates whether PivotItem names should be repeated at the top of each printed page. |
| RepeatItemsOnEachPrintedPage | boolean | |
| PrintTitles | boolean | Indicates whether the print titles for the worksheet are set based on the PivotTable report. The default value is false. |
| DisplayImmediateItems | boolean | Indicates whether items in the row and column areas are visible when the data area of the PivotTable is empty. The defau |
| IsSelected | boolean | Indicates whether this PivotTable is selected. |
| ShowPivotStyleRowHeader | boolean | Indicates whether the row header in the pivot table should have the style applied. |
| ShowPivotStyleColumnHeader | boolean | Indicates whether the column header in the pivot table should have the style applied. |
| ShowPivotStyleRowStripes | boolean | Indicates whether row stripe formatting is applied. |
| ShowPivotStyleColumnStripes | boolean | Indicates whether stripe formatting is applied for column. |
| ShowPivotStyleLastColumn | boolean | Indicates whether the column formatting is applied. |
Methods
| Name | Description |
|---|---|
| getHorizontalPageBreaks | |
| getHorizontalBreaks | get pivot table row index list of horizontal pagebreaks |
| showInCompactForm | Layouts the PivotTable in compact form. |
| showInOutlineForm | Layouts the PivotTable in outline form. |
| showInTabularForm | Layouts the PivotTable in tabular form. |
| getCellByDisplayName | Gets the Cell object by the display name of PivotField. |
| getDependentPivotTables | |
| getChildren | Gets the Children Pivot Tables which use this PivotTable data as data source. |
| getSourceDataConnections | |
| getNamesOfSourceDataConnections | |
| changeDataSource | Set pivottable’s source data. Sheet1!$A$1:$C$3 |
| getSource | Get pivottable’s source data. |
| refreshData | Refreshes pivottable’s data and setting from it’s data source. |
We will gather data from data source to a pivot cache ,t | | calculateData | Calculates pivottable’s data to cells.
Cell.Value in the pivot range could not return the correct result if the method | | getPivotTablesWithSamePivotCache | | | clearData | Clear PivotTable’s data and formatting
If this method is not called before you add or delete PivotField, Maybe the Pivo | | clearFilters | | | clearAll | | | calculateRange | Calculates pivottable’s range.
If this method is not been called,maybe the pivottable range is not corrected. | | formatAll | Format all the cell in the pivottable area | | formatRow | Format the row data in the pivottable area | | format | Formats selected area of the PivotTable. | | selectArea | | | showDetail | | | setAutoGroupField | Sets auto field group by the PivotTable.
baseFieldIndex - The row or column field index in the base fields NOTE: This m | | setManualGroupField | Sets manual field group by the PivotTable.
NOTE: This method is now obsolete. Instead, please use PivotField.GroupBy() | | setUngroup | Sets ungroup by the PivotTable
NOTE: This method is now obsolete. Instead, please use PivotField.Ungroup() method. This | | dispose | Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. | | copyStyle | Copies named style from another pivot table. | | showReportFilterPage | Show all the report filter pages according to PivotField, the PivotField must be located in the PageFields. | | showReportFilterPageByName | Show all the report filter pages according to PivotField’s name, the PivotField must be located in the PageFields. | | showReportFilterPageByIndex | Show all the report filter pages according to the position index in the PageFields | | removeField | Removes a field from specific field area | | addFieldToArea | Adds the field to the specific area. | | addCalculatedField | Adds a calculated field to pivot field. | | getFields | Gets the specific pivot field list by the region. | | fields | Gets the specific fields by the field type.
NOTE: This method is now obsolete. Instead, please use PivotField.GetFields | | getButtonArea | | | move | Moves the PivotTable to a different location in the worksheet. | | moveTo | |
PivotTable.PivotCache property
Type: PivotCache
PivotTable.IsExcel2003Compatible property
Specifies whether the PivotTable is compatible for Excel2003 when refreshing PivotTable, if true, a string must be less than or equal to 255 characters, so if the string is greater than 255 characters, it will be truncated. if false, a string will not have the aforementioned restriction. The default value is true.
Type: boolean
PivotTable.RefreshedByWho property
Gets the name of the last user who refreshed this PivotTable
Type: String
PivotTable.RefreshDate property
Gets the last date time when the PivotTable was refreshed.
Type: DateTime
PivotTable.PivotTableStyle property
Type: TableStyle
PivotTable.PivotTableStyleName property
Gets and sets the pivottable style name.
Type: String
PivotTable.PivotTableStyleType property
Gets and sets the built-in pivot table style. The value of the property is PivotTableStyleType integer constant.
Type: int
PivotTable.ColumnFields property
Returns a PivotFields object that are currently shown as column fields.
Type: PivotFieldCollection
PivotTable.RowFields property
Returns a PivotFields object that are currently shown as row fields.
Type: PivotFieldCollection
PivotTable.PageFields property
Returns a PivotFields object that are currently shown as page fields.
Type: PivotFieldCollection
PivotTable.DataFields property
Gets a PivotField object that represents all the data fields in a PivotTable. Read-only.It would be init only when there are two or more data fields in the DataPiovtFiels. It only use to add DataPivotField to the PivotTable row/column area . Default is in row area.
Type: PivotFieldCollection
PivotTable.DataField property
Gets a PivotField object that represents all the data fields in a PivotTable. Read-only. It would only be created when there are two or more data fields in the Data region. Defaultly it is in row region. You can drag it to the row/column region with PivotTable.AddFieldToArea() method .
Type: PivotField
PivotTable.ValuesField property
Type: PivotField
PivotTable.BaseFields property
Returns all base pivot fields in the PivotTable.
Type: PivotFieldCollection
PivotTable.PivotFilters property
Returns a list of pivot filters.
Type: PivotFilterCollection
PivotTable.TopRightArea property
Type: CellArea
PivotTable.FilterArea property
Type: CellArea
PivotTable.ColumnRange property
Returns a CellArea object that represents the range that contains the column area in the PivotTable report. Read-only.
Type: CellArea
PivotTable.RowRange property
Returns a CellArea object that represents the range that contains the row area in the PivotTable report. Read-only.
Type: CellArea
PivotTable.DataBodyRange property
Returns a CellArea object that represents the range that contains the data area in the list between the header row and the insert row. Read-only.
Type: CellArea
PivotTable.TableRange1 property
Returns a CellArea object that represents the range containing the entire PivotTable report, but doesn’t include page fields. Read-only.
Type: CellArea
PivotTable.TableRange2 property
Returns a CellArea object that represents the range containing the entire PivotTable report, includes page fields. Read-only.
Type: CellArea
PivotTable.IsGridDropZones property
Indicates whether the PivotTable report displays classic pivottable layout. (enables dragging fields in the grid)
Type: boolean
PivotTable.ShowColumnGrandTotals property
Type: boolean
PivotTable.ShowRowGrandTotals property
Type: boolean
PivotTable.ColumnGrand property
Indicates whether the PivotTable report shows grand totals for columns.
Type: boolean
PivotTable.RowGrand property
Indicates whether the PivotTable report shows grand totals for rows.
Type: boolean
PivotTable.DisplayNullString property
Indicates whether the PivotTable report displays a custom string if the value is null.
Type: boolean
PivotTable.NullString property
Gets the string displayed in cells that contain null values when the DisplayNullString property is true.The default value is an empty string.
Type: String
PivotTable.DisplayErrorString property
Indicates whether the PivotTable report displays a custom string in cells that contain errors.
Type: boolean
PivotTable.DataFieldHeaderName property
Gets and sets the name of the value area field header in the PivotTable.
Type: String
PivotTable.ErrorString property
Gets the string displayed in cells that contain errors when the DisplayErrorString property is true.The default value is an empty string.
Type: String
PivotTable.IsAutoFormat property
Indicates whether the PivotTable report is automatically formatted. Checkbox “autoformat table " which is in pivottable option for Excel 2003
Type: boolean
PivotTable.AutofitColumnWidthOnUpdate property
Indicates whether autofitting column width on update
Type: boolean
PivotTable.AutoFormatType property
Gets and sets the auto format type of PivotTable. The value of the property is PivotTableAutoFormatType integer constant.
Type: int
PivotTable.HasBlankRows property
Indicates whether to add blank rows. This property only applies for the PivotTable auto format types which needs to add blank rows.
Type: boolean
PivotTable.MergeLabels property
True if the specified PivotTable report’s outer-row item, column item, subtotal, and grand total labels use merged cells.
Type: boolean
PivotTable.PreserveFormatting property
Indicates whether formatting is preserved when the PivotTable is refreshed or recalculated.
Type: boolean
PivotTable.ShowDrill property
Gets and sets whether showing expand/collapse buttons.
Type: boolean
PivotTable.EnableDrilldown property
Gets whether drilldown is enabled.
Type: boolean
PivotTable.EnableFieldDialog property
Indicates whether the PivotTable Field dialog box is available when the user double-clicks the PivotTable field.
Type: boolean
PivotTable.EnableFieldList property
Gets whether enable the field list for the PivotTable.
Type: boolean
PivotTable.EnableWizard property
Indicates whether the PivotTable Wizard is available.
Type: boolean
PivotTable.SubtotalHiddenPageItems property
Indicates whether hidden page field items in the PivotTable report are included in row and column subtotals, block totals, and grand totals. The default value is False.
Type: boolean
PivotTable.GrandTotalName property
Returns the text string label that is displayed in the grand total column or row heading. The default value is the string “Grand Total”.
Type: String
PivotTable.ManualUpdate property
Indicates whether the PivotTable report is recalculated only at the user’s request.
Type: boolean
PivotTable.IsMultipleFieldFilters property
Specifies a boolean value that indicates whether the fields of a PivotTable can have multiple filters set on them.
Type: boolean
PivotTable.AllowMultipleFiltersPerField property
Type: boolean
PivotTable.MissingItemsLimit property
Specifies a boolean value that indicates whether the fields of a PivotTable can have multiple filters set on them. The value of the property is PivotMissingItemLimitType integer constant.
Type: int
PivotTable.EnableDataValueEditing property
Specifies a boolean value that indicates whether the user is allowed to edit the cells in the data area of the pivottable. Enable cell editing in the values area
Type: boolean
PivotTable.ShowDataTips property
Specifies a boolean value that indicates whether tooltips should be displayed for PivotTable data cells.
Type: boolean
PivotTable.ShowMemberPropertyTips property
Specifies a boolean value that indicates whether member property information should be omitted from PivotTable tooltips.
Type: boolean
PivotTable.ShowValuesRow property
Specifies a boolean value that indicates whether show values row. show the values row
Type: boolean
PivotTable.ShowEmptyCol property
Specifies a boolean value that indicates whether to include empty columns in the table
Type: boolean
PivotTable.ShowEmptyRow property
Specifies a boolean value that indicates whether to include empty rows in the table.
Type: boolean
PivotTable.FieldListSortAscending property
Indicates whether fields in the PivotTable are sorted in non-default order in the field list.
Type: boolean
PivotTable.PrintDrill property
Specifies a boolean value that indicates whether drill indicators should be printed. print expand/collapse buttons when displayed on pivottable.
Type: boolean
PivotTable.AltTextTitle property
Gets the title of the altertext
Type: String
PivotTable.AltTextDescription property
Gets the description of the alt text
Type: String
PivotTable.Name property
Gets the name of the PivotTable
Type: String
PivotTable.ColumnHeaderCaption property
Gets the Column Header Caption of the PivotTable.
Type: String
PivotTable.Indent property
Specifies the indentation increment for compact axis and can be used to set the Report Layout to Compact Form.
Type: int
PivotTable.RowHeaderCaption property
Gets the Row Header Caption of the PivotTable.
Type: String
PivotTable.ShowRowHeaderCaption property
Indicates whether row header caption is shown in the PivotTable report Indicates whether Display field captions and filter drop downs
Type: boolean
PivotTable.CustomListSort property
Indicates whether consider built-in custom list when sort data
Type: boolean
PivotTable.PivotFormatConditions property
Gets the Format Conditions of the pivot table.
Type: PivotFormatConditionCollection
PivotTable.ConditionalFormats property
Type: PivotConditionalFormatCollection
PivotTable.PageFieldOrder property
Gets the order in which page fields are added to the PivotTable report’s layout. The value of the property is PrintOrderType integer constant.
Type: int
PivotTable.PageFieldWrapCount property
Gets the number of page fields in each column or row in the PivotTable report.
Type: int
PivotTable.Tag property
Gets a string saved with the PivotTable report.
Type: String
PivotTable.SaveData property
Indicates whether data for the PivotTable report is saved with the workbook.
Type: boolean
PivotTable.RefreshDataOnOpeningFile property
Indicates whether Refresh Data when Opening File.
Type: boolean
PivotTable.RefreshDataFlag property
Indicates whether Refreshing Data or not.
Type: boolean
PivotTable.SourceType property
The value of the property is PivotTableSourceType integer constant.
Type: byte
PivotTable.ExternalConnectionDataSource property
Gets the external connection data source.
Type: ExternalConnection
PivotTable.DataSource property
Gets and sets the data source of the pivot table.
Type: String[]
PivotTable.PivotFormats property
Gets the collection of formats applied to PivotTable.
Type: PivotTableFormatCollection
PivotTable.ItemPrintTitles property
Indicates whether PivotItem names should be repeated at the top of each printed page.
Type: boolean
PivotTable.RepeatItemsOnEachPrintedPage property
Type: boolean
PivotTable.PrintTitles property
Indicates whether the print titles for the worksheet are set based on the PivotTable report. The default value is false.
Type: boolean
PivotTable.DisplayImmediateItems property
Indicates whether items in the row and column areas are visible when the data area of the PivotTable is empty. The default value is true.
Type: boolean
PivotTable.IsSelected property
Indicates whether this PivotTable is selected.
Type: boolean
PivotTable.ShowPivotStyleRowHeader property
Indicates whether the row header in the pivot table should have the style applied.
Type: boolean
PivotTable.ShowPivotStyleColumnHeader property
Indicates whether the column header in the pivot table should have the style applied.
Type: boolean
PivotTable.ShowPivotStyleRowStripes property
Indicates whether row stripe formatting is applied.
Type: boolean
PivotTable.ShowPivotStyleColumnStripes property
Indicates whether stripe formatting is applied for column.
Type: boolean
PivotTable.ShowPivotStyleLastColumn property
Indicates whether the column formatting is applied.
Type: boolean
getHorizontalPageBreaks()
getHorizontalBreaks()
get pivot table row index list of horizontal pagebreaks
showInCompactForm()
Layouts the PivotTable in compact form.
showInOutlineForm()
Layouts the PivotTable in outline form.
showInTabularForm()
Layouts the PivotTable in tabular form.
getCellByDisplayName(displayName)
Gets the Cell object by the display name of PivotField.
| Parameter | Type | Description |
|---|---|---|
| displayName | String | the DisplayName of PivotField |
Returns: the Cell object
getDependentPivotTables()
getChildren()
Gets the Children Pivot Tables which use this PivotTable data as data source.
Returns: the PivotTable array object
getSourceDataConnections()
getNamesOfSourceDataConnections()
changeDataSource(source)
Set pivottable’s source data. Sheet1!$A$1:$C$3
getSource() (1 of 2)
Get pivottable’s source data.
getSource(isOriginal) (2 of 2)
refreshData() (1 of 2)
Refreshes pivottable’s data and setting from it’s data source.
We will gather data from data source to a pivot cache ,then calculate the data in the cache to the cells. This method is only used to gather all data to a pivot cache.
refreshData(option) (2 of 2)
Refreshes pivottable’s data and setting from it’s data source with options.
| Parameter | Type | Description |
|---|---|---|
| option | PivotTableRefreshOption | The options for refreshing data source of pivot table. |
calculateData() (1 of 2)
Calculates pivottable’s data to cells.
Cell.Value in the pivot range could not return the correct result if the method is not been called. This method calculates data with an inner pivot cache,not original data source. So if the data source is changed, please call RefreshData() method first.
calculateData(option) (2 of 2)
Calculating pivot tables with options
| Parameter | Type | Description |
|---|---|---|
| option | PivotTableCalculateOption |
getPivotTablesWithSamePivotCache()
clearData()
Clear PivotTable’s data and formatting
If this method is not called before you add or delete PivotField, Maybe the PivotTable data is not corrected
clearFilters()
clearAll()
calculateRange()
Calculates pivottable’s range.
If this method is not been called,maybe the pivottable range is not corrected.
formatAll(style)
Format all the cell in the pivottable area
| Parameter | Type | Description |
|---|---|---|
| style | Style | Style which is to format |
formatRow(row, style)
Format the row data in the pivottable area
| Parameter | Type | Description |
|---|---|---|
| row | int | Row Index of the Row object |
| style | Style | Style which is to format |
format(pivotArea, style) (1 of 3)
Formats selected area of the PivotTable.
| Parameter | Type | Description |
|---|---|---|
| pivotArea | PivotArea | |
| style | Style |
format(ca, style) (2 of 3)
format(row, column, style) (3 of 3)
Format the cell in the pivottable area
| Parameter | Type | Description |
|---|---|---|
| row | int | Row Index of the cell |
| column | int | Column index of the cell |
| style | Style | Style which is to format the cell |
selectArea(ca)
showDetail(rowOffset, columnOffset, newSheet, destRow, destColumn)
setAutoGroupField(baseFieldIndex) (1 of 2)
Sets auto field group by the PivotTable.
baseFieldIndex - The row or column field index in the base fields NOTE: This method is now obsolete. Instead, please use PivotField.GroupBy() method. This method will be removed 12 months later since October 2023. Aspose apologizes for any inconvenience you may have experienced.
setAutoGroupField(pivotField) (2 of 2)
Sets auto field group by the PivotTable.
NOTE: This method is now obsolete. Instead, please use PivotField.GroupBy() method. This method will be removed 12 months later since October 2023. Aspose apologizes for any inconvenience you may have experienced.
| Parameter | Type | Description |
|---|---|---|
| pivotField | PivotField | The row or column field in the specific fields |
setManualGroupField(baseFieldIndex, startVal, endVal, groupByList, intervalNum) (1 of 4)
Sets manual field group by the PivotTable.
NOTE: This method is now obsolete. Instead, please use PivotField.GroupBy() method. This method will be removed 12 months later since October 2023. Aspose apologizes for any inconvenience you may have experienced.
| Parameter | Type | Description |
|---|---|---|
| baseFieldIndex | int | The row or column field index in the base fields |
| startVal | float | Specifies the starting value for numeric grouping. |
| endVal | float | Specifies the ending value for numeric grouping. |
| groupByList | ArrayList | Specifies the grouping type list. Specified by PivotTableGroupType |
| intervalNum | float | Specifies the interval number group by numeric grouping. |
setManualGroupField(pivotField, startVal, endVal, groupByList, intervalNum) (2 of 4)
Sets manual field group by the PivotTable.
NOTE: This method is now obsolete. Instead, please use PivotField.GroupBy() method. This method will be removed 12 months later since October 2023. Aspose apologizes for any inconvenience you may have experienced.
| Parameter | Type | Description |
|---|---|---|
| pivotField | PivotField | The row or column field in the base fields |
| startVal | float | Specifies the starting value for numeric grouping. |
| endVal | float | Specifies the ending value for numeric grouping. |
| groupByList | ArrayList | Specifies the grouping type list. Specified by PivotTableGroupType |
| intervalNum | float | Specifies the interval number group by numeric grouping. |
setManualGroupField(baseFieldIndex, startVal, endVal, groupByList, intervalNum) (3 of 4)
Sets manual field group by the PivotTable.
NOTE: This method is now obsolete. Instead, please use PivotField.GroupBy() method. This method will be removed 12 months later since October 2023. Aspose apologizes for any inconvenience you may have experienced.
| Parameter | Type | Description |
|---|---|---|
| baseFieldIndex | int | The row or column field index in the base fields |
| startVal | DateTime | Specifies the starting value for date grouping. |
| endVal | DateTime | Specifies the ending value for date grouping. |
| groupByList | ArrayList | Specifies the grouping type list. Specified by PivotTableGroupType |
| intervalNum | int | Specifies the interval number group by in days grouping.The number of days must be positive integer of nonzero |
setManualGroupField(pivotField, startVal, endVal, groupByList, intervalNum) (4 of 4)
Sets manual field group by the PivotTable.
NOTE: This method is now obsolete. Instead, please use PivotField.GroupBy() method. This method will be removed 12 months later since October 2023. Aspose apologizes for any inconvenience you may have experienced.
| Parameter | Type | Description |
|---|---|---|
| pivotField | PivotField | The row or column field in the base fields |
| startVal | DateTime | Specifies the starting value for date grouping. |
| endVal | DateTime | Specifies the ending value for date grouping. |
| groupByList | ArrayList | Specifies the grouping type list. Specified by PivotTableGroupType |
| intervalNum | int | Specifies the interval number group by in days grouping.The number of days must be positive integer of nonzero |
setUngroup(baseFieldIndex) (1 of 2)
Sets ungroup by the PivotTable
NOTE: This method is now obsolete. Instead, please use PivotField.Ungroup() method. This method will be removed 12 months later since October 2023. Aspose apologizes for any inconvenience you may have experienced.
| Parameter | Type | Description |
|---|---|---|
| baseFieldIndex | int | The row or column field index in the base fields |
setUngroup(pivotField) (2 of 2)
Sets ungroup by the PivotTable
NOTE: This method is now obsolete. Instead, please use PivotField.Ungroup() method. This method will be removed 12 months later since October 2023. Aspose apologizes for any inconvenience you may have experienced.
| Parameter | Type | Description |
|---|---|---|
| pivotField | PivotField | The row or column field in the base fields |
dispose()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
copyStyle(pivotTable)
Copies named style from another pivot table.
| Parameter | Type | Description |
|---|---|---|
| pivotTable | PivotTable | Source pivot table. |
showReportFilterPage(pageField)
Show all the report filter pages according to PivotField, the PivotField must be located in the PageFields.
| Parameter | Type | Description |
|---|---|---|
| pageField | PivotField | The PivotField object |
showReportFilterPageByName(fieldName)
Show all the report filter pages according to PivotField’s name, the PivotField must be located in the PageFields.
| Parameter | Type | Description |
|---|---|---|
| fieldName | String | The name of PivotField |
showReportFilterPageByIndex(posIndex)
Show all the report filter pages according to the position index in the PageFields
| Parameter | Type | Description |
|---|---|---|
| posIndex | int | The position index in the PageFields |
removeField(fieldType, fieldName) (1 of 3)
Removes a field from specific field area
| Parameter | Type | Description |
|---|---|---|
| fieldType | int | A PivotFieldType value. The fields area type. |
| fieldName | String | The name in the base fields. |
removeField(fieldType, baseFieldIndex) (2 of 3)
Removes a field from specific field area
| Parameter | Type | Description |
|---|---|---|
| fieldType | int | A PivotFieldType value. The fields area type. |
| baseFieldIndex | int | The field index in the base fields. |
removeField(fieldType, pivotField) (3 of 3)
Remove field from specific field area
| Parameter | Type | Description |
|---|---|---|
| fieldType | int | A PivotFieldType value. the fields area type. |
| pivotField | PivotField | the field in the base fields. |
addFieldToArea(fieldType, fieldName) (1 of 3)
Adds the field to the specific area.
| Parameter | Type | Description |
|---|---|---|
| fieldType | int | A PivotFieldType value. The fields area type. |
| fieldName | String | The name in the base fields. |
Returns: The field position in the specific fields.If there is no field named as it, return -1.
addFieldToArea(fieldType, baseFieldIndex) (2 of 3)
Adds the field to the specific area.
| Parameter | Type | Description |
|---|---|---|
| fieldType | int | A PivotFieldType value. The fields area type. |
| baseFieldIndex | int | The field index in the base fields. |
Returns: The field position in the specific fields.
addFieldToArea(fieldType, pivotField) (3 of 3)
Adds the field to the specific area.
| Parameter | Type | Description |
|---|---|---|
| fieldType | int | A PivotFieldType value. the fields area type. |
| pivotField | PivotField | the field in the base fields. |
Returns: the field position in the specific fields.
addCalculatedField(name, formula, dragToDataArea) (1 of 2)
Adds a calculated field to pivot field.
| Parameter | Type | Description |
|---|---|---|
| name | String | The name of the calculated field |
| formula | String | The formula of the calculated field. |
| dragToDataArea | boolean | True,drag this field to data area immediately |
addCalculatedField(name, formula) (2 of 2)
Adds a calculated field to pivot field and drag it to data area.
| Parameter | Type | Description |
|---|---|---|
| name | String | The name of the calculated field |
| formula | String | The formula of the calculated field. |
getFields(fieldType)
Gets the specific pivot field list by the region.
| Parameter | Type | Description |
|---|---|---|
| fieldType | int | A PivotFieldType value. the region type. |
Returns: the specific pivot field collection
fields(fieldType)
Gets the specific fields by the field type.
NOTE: This method is now obsolete. Instead, please use PivotField.GetFields() method. This method will be removed 12 months later since May 2024. Aspose apologizes for any inconvenience you may have experienced.
| Parameter | Type | Description |
|---|---|---|
| fieldType | int | A PivotFieldType value. the field type. |
Returns: the specific field collection
getButtonArea(axisType)
move(row, column) (1 of 2)
Moves the PivotTable to a different location in the worksheet.
| Parameter | Type | Description |
|---|---|---|
| row | int | row index. |
| column | int | column index. |
move(destCellName) (2 of 2)
Moves the PivotTable to a different location in the worksheet.
| Parameter | Type | Description |
|---|---|---|
| destCellName | String | the dest cell name. |