Class ExcelPivotTableField
A pivot table field.
Inherited Members
Namespace: OfficeOpenXml.Table.PivotTable
Assembly: EPPlus.dll
Syntax
public class ExcelPivotTableField : XmlHelper
Properties
Axis
Type of axis
Declaration
public ePivotFieldAxis Axis { get; }
Property Value
Type | Description |
---|---|
ePivotFieldAxis |
Compact
Compact mode
Declaration
public bool Compact { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
Grouping
Grouping settings. Null if the field has no grouping otherwise ExcelPivotTableFieldNumericGroup or ExcelPivotTableFieldNumericGroup.
Declaration
public ExcelPivotTableFieldGroup Grouping { get; }
Property Value
Type | Description |
---|---|
ExcelPivotTableFieldGroup |
IncludeNewItemsInFilter
A boolean that indicates whether manual filter is in inclusive mode
Declaration
public bool IncludeNewItemsInFilter { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
Index
The index of the pivot table field
Declaration
public int Index { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 |
IsColumnField
If the field is a column field
Declaration
public bool IsColumnField { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
IsDataField
If the field is a datafield
Declaration
public bool IsDataField { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
IsPageField
If the field is a page field.
Declaration
public bool IsPageField { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
IsRowField
If the field is a row field
Declaration
public bool IsRowField { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
Items
Pivottable field Items. Used for grouping.
Declaration
public ExcelPivotTableFieldCollectionBase<ExcelPivotTableFieldItem> Items { get; }
Property Value
Type | Description |
---|---|
ExcelPivotTableFieldCollectionBase<ExcelPivotTableFieldItem> |
MultipleItemSelectionAllowed
Indicates whether the field can have multiple items selected in the page field
Declaration
public bool MultipleItemSelectionAllowed { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
Name
Name of the field
Declaration
public string Name { get; set; }
Property Value
Type | Description |
---|---|
System.String |
Outline
A boolean that indicates whether the items in this field should be shown in Outline form
Declaration
public bool Outline { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
PageFieldSettings
Page field settings
Declaration
public ExcelPivotTablePageFieldSettings PageFieldSettings { get; }
Property Value
Type | Description |
---|---|
ExcelPivotTablePageFieldSettings |
ShowAll
Indicates whether to show all items for this field
Declaration
public bool ShowAll { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
ShowAsCaption
Indicates whether to show the property as a member caption
Declaration
public bool ShowAsCaption { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
ShowDropDowns
Indicates whether to hide drop down buttons on PivotField headers
Declaration
public bool ShowDropDowns { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
ShowInFieldList
Indicates whether this hierarchy is omitted from the field list
Declaration
public bool ShowInFieldList { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
ShowMemberPropertyInCell
Indicates whether to show the member property value in a PivotTable cell
Declaration
public bool ShowMemberPropertyInCell { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
ShowMemberPropertyToolTip
Indicates whether to show the member property value in a tooltip on the appropriate PivotTable cells
Declaration
public bool ShowMemberPropertyToolTip { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
Sort
The type of sort that is applied to this field
Declaration
public eSortType Sort { get; set; }
Property Value
Type | Description |
---|---|
eSortType |
SubTotalFunctions
Enumeration of the different subtotal operations that can be applied to page, row or column fields
Declaration
public eSubTotalFunctions SubTotalFunctions { get; set; }
Property Value
Type | Description |
---|---|
eSubTotalFunctions |
SubtotalTop
The custom text that is displayed for the subtotals label
Declaration
public bool SubtotalTop { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
Methods
AddDateGrouping(eDateGroupBy)
Add a date grouping on this field.
Declaration
public void AddDateGrouping(eDateGroupBy groupBy)
Parameters
Type | Name | Description |
---|---|---|
eDateGroupBy | groupBy | Group by |
AddDateGrouping(eDateGroupBy, DateTime, DateTime)
Add a date grouping on this field.
Declaration
public void AddDateGrouping(eDateGroupBy groupBy, DateTime startDate, DateTime endDate)
Parameters
Type | Name | Description |
---|---|---|
eDateGroupBy | groupBy | Group by |
System.DateTime | startDate | Fixed start date. Use DateTime.MinValue for auto |
System.DateTime | endDate | Fixed end date. Use DateTime.MaxValue for auto |
AddDateGrouping(Int32, DateTime, DateTime)
Add a date grouping on this field.
Declaration
public void AddDateGrouping(int days, DateTime startDate, DateTime endDate)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | days | Number of days when grouping on days |
System.DateTime | startDate | Fixed start date. Use DateTime.MinValue for auto |
System.DateTime | endDate | Fixed end date. Use DateTime.MaxValue for auto |
AddNumericGrouping(Double, Double, Double)
Add numberic grouping to the field
Declaration
public void AddNumericGrouping(double Start, double End, double Interval)
Parameters
Type | Name | Description |
---|---|---|
System.Double | Start | Start value |
System.Double | End | End value |
System.Double | Interval | Interval |