Click or drag to resize

XlsPivotTable Class

Represents a pivot table in an Excel worksheet, providing functionalities to manipulate and retrieve data from pivot tables.
Inheritance Hierarchy
System Object
Spire.Xls.Core.Spreadsheet XlsObject
Spire.Xls.Core.Spreadsheet.PivotTables XlsPivotTable
Spire.Xls PivotTable

Namespace: Spire.Xls.Core.Spreadsheet.PivotTables
Assembly: Spire.XLS (in Spire.XLS.dll) Version: 15.4.0.0 (15.4.0.5046)
Syntax
public class XlsPivotTable : XlsObject, 
	IPivotTable

The XlsPivotTable type exposes the following members.

Constructors
Name Description
Public method XlsPivotTable
Creates collection and sets its Application and Parent values.
Top
Properties
Name Description
Public property AllSubTotalTop
Indicated whether diplay all subtotal at top of group, Change will cover every field's setting
Public property AutoFormatType
Gets/sets the auto format type of PivotTable.
Public property BuiltInStyle
Gets/sets built-in pivot style.
Public property Cache
Returns cache used by this pivot table. Read-only.
Public property CacheIndex
Gets Index of the pivot Cache.Read-only.
Public property CalculatedFields
Returns the collection of calculated fields of the specified pivot table.Read-only.
Public property ColumnFields
Returns the collection of Column field for the specified pivot table.Read-only.
Public property ColumnsPerPage
Specifies the number of columns per page for this PivotTable that the filter area will occupy.
Public property CustomTableStyleName
Gets or sets the name of the custom table style for the pivot table.
Public property DataFields
Gets collection of pivot table data fields. Read-only.
Public property DisplayErrorString
True if the PivotTable report displays a custom error string in cells that contain errors. The default value is False.
Public property DisplayFieldCaptions
Gets/sets value controlling whether or not filter buttons and PivotField captions for rows and columns are displayed in the grid.
Public property DisplayNullString
True if the PivotTable report displays a custom string in cells that contain null values. The default value is True.
Public property EnableDrilldown
True if drilldown is enabled. The default value is True.
Public property EnableFieldDialog
True if the PivotTable Field dialog box is available when the user double-clicks the PivotTable field. The default value is True.
Public property EnableWizard
True if the PivotTable Wizard is available. The default value is True.
Public property ErrorString
Returns or sets the string displayed in cells that contain errors when the DisplayErrorString property is True.
Public property FirstDataCol
Specifies the first column of the PivotTable data, relative to the top left cell in the ref value
Public property FirstDataRow
Specifies the first column of the PivotTable data, relative to the top left cell in the ref value
Public property FirstHeaderRow
Specifies the first row of the PivotTable header, relative to the top left cell in the ref value.
Public property IsColumnGrand
Gets/sets value indicating whether the PivotTable contains column with grand totals for rows (same as ColumnGrand in VBA).
Public property IsCompatibleWithExcel2003
Gets/sets whether compatible with excel2003. The default value is true.
Public property IsRowGrand
Gets/sets value indicating whether the PivotTable contains row with grand totals for columns (same as RowGrand in VBA).
Public property Location
Returns pivot table location.
Public property ManualUpdate
True if the PivotTable report is recalculated only at the user's request. The default value is False.
Public property MergeLabels
True if the specified PivotTable report outer-row item, column item, subtotal, and grand total labels use merged cells.
Public property Name
Gets pivot table name. Read-only.
Public property NullString
Returns or sets the string displayed in cells that contain null values when the DisplayNullString property is True.
Public property Options
Represents the pivot table options.Read-only
Public property PageFieldOrder
Returns or sets the order in which page fields are added to the PivotTable report layout.
Public property PageFields
Returns the collection of page field for the specified pivot table,Read-only.
Public property PageFieldStyle
Returns or sets the style used in the bound page field area. The default value is a null string (no style is applied by default).
Public property PageFieldWrapCount
Returns or sets the number of page fields in each column or row in the PivotTable report.
Public property Parent
Gets the parent XlsPivotTablesCollection of the current instance.
Public property PivotConditionalFormats
Returns collection of pivot conditional format. Read-only.
Public property PivotFields
Gets collection of pivot fields. Read-only.
Protected property ReferenceCount
Get quantity of instance references.
(Inherited from XlsObject .)
Public property RepeatItemsOnEachPrintedPage
True if row, column, and item labels appear on the first row of each page when the specified PivotTable report is printed. False if labels are printed only on the first page. The default value is True.
Public property ReportFilters
Gets or sets report filter collection
Public property RowFields
Returns the collection of Row field for the specified pivot table.Read-only.
Public property RowsPerPage
Specifies the number of rows per page for this PivotTable that the filter area will occupy.Read-only.
Public property ShowColHeaderStyle
Specifies a boolean value that indicates whether to show column headers for the table.
Public property ShowColStripes
Specifies a boolean value that indicates whether to show column stripe formatting for the table.
Public property ShowColumnGrand
Gets/sets value indicating whether the PivotTable contains grand totals for columns.
Public property ShowDataFieldInRow
Represents the pivot table to add the Calculated Data field in rows
Public property ShowDrillIndicators
The ShowDrillIndicators property is used for toggling the display of drill indicators in the PivotTable.
Public property ShowLastCol
Specifies a boolean value that indicates whether to show the last column.
Public property ShowRowGrand
Gets/sets value indicating whether the PivotTable contains grand totals for rows.
Public property ShowRowHeaderStyle
Specifies a boolean value that indicates whether to show row headers for the table.
Public property ShowRowStripes
Specifies a boolean value that indicates whether to show row stripe formatting for the table.
Public property ShowSubtotals
Gets or sets a value indicating whether subtotals are shown for all fields in the pivot table.
Public property Workbook
Gets parent workbook. Read-only.
Public property Worksheet
Gets the worksheet associated with the current instance.
Top
Methods
Name Description
Protected method AddReference
Increase the quantity of reference. User must use this method when new wrapper on object is created or reference on object stored.
(Inherited from XlsObject .)
Public method ApplyStyleToRange
Apply style to range in pivot table.
Public method CalculateData
Calculates pivottable's data to cells.
Public method ChangeDataSource
Change the data source of pivotTable.
Protected method CheckDisposed
Checks whether object was disposed and throws exception if it was.
(Inherited from XlsObject .)
Public method Clear
This method clears all the fields, deletes all filtering and sorting applied to the PivotTable.
Public method ClearColumnFieldFilter
clear the column field filter.
Public method ClearFilter
clear the row and column field filter depends on field name.
Public method ClearRowFieldFilter
clear the row field filter.
Public method Clone(Object)
Creates a clone of the specified parent object using the default cache index and no additional parameters.
Public method Clone(Object, Int32, Dictionary String, String )
Creates a clone of the specified object with additional parameters for caching and worksheet name mapping.
Public method Dispose
Dispose object and free resources.
(Inherited from XlsObject .)
Public method Equals
Determines whether the specified object is equal to the current object.
(Inherited from Object .)
Protected method Finalize
Destructor. Call dispose method of current object.
(Inherited from XlsObject .)
Protected method FindParent(Type)
This method is used to find parent with specific type.
(Inherited from XlsObject .)
Protected method FindParent( Type )
Find parent of object.
(Inherited from XlsObject .)
Protected method FindParent(Type, Boolean)
This method is used to find parent with specific type.
(Inherited from XlsObject .)
Protected method FindParents
Finds parent objects.
(Inherited from XlsObject .)
Public method GetHashCode
Serves as the default hash function.
(Inherited from Object .)
Public method GetType
Gets the Type of the current instance.
(Inherited from Object .)
Protected method MemberwiseClone
Creates a shallow copy of the current Object .
(Inherited from Object .)
Protected method OnDispose
Method which can be overriden by users to take any specific actions when object is disposed.
(Inherited from XlsObject .)
Protected method ReleaseReference
Decrease quantity of Reference. User must call this method when freeing resources.
(Inherited from XlsObject .)
Protected method SetParent
Sets parent of the object.
(Inherited from XlsObject .)
Public method ToString
Returns a string that represents the current object.
(Inherited from Object .)
Top
Fields
Name Description
Protected field m_bIsDisposed
Flag which indicates if the object was disposed or not.
(Inherited from XlsObject .)
Top
See Also