Show / Hide Table of Contents

Class ExcelPivotTableCalculatedData

Represents a selection of a row or column field to retreive the calculated value from a pivot table.

Inheritance
System.Object
ExcelPivotTableCalculatedData
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: OfficeOpenXml.Table.PivotTable
Assembly: EPPlus.dll
Syntax
public class ExcelPivotTableCalculatedData

Methods

GetValue(Int32)

Get the value for the current field selection. SelectField(String, Object) SelectField(String, Object, eSubTotalFunctions)

Declaration
public object GetValue(int dataFieldIndex = 0)
Parameters
Type Name Description
System.Int32 dataFieldIndex

The index for the date field in the DataFields collection

Returns
Type Description
System.Object

The value from the pivot table. If data field does not exist of the selected fields does not match any part of the pivot table a #REF! error is retuned.

GetValue(String)

Get the value for the current field selection. SelectField(String, Object) SelectField(String, Object, eSubTotalFunctions)

Declaration
public object GetValue(string dataFieldName)
Parameters
Type Name Description
System.String dataFieldName
Returns
Type Description
System.Object

SelectField(String, Object)

Specifies which value to use for a field.

Declaration
public ExcelPivotTableCalculatedData SelectField(string fieldName, object value)
Parameters
Type Name Description
System.String fieldName

The name of the field

System.Object value

The value

Returns
Type Description
ExcelPivotTableCalculatedData

A new ExcelPivotTableCalculatedData to select other row or column field values or fetch the calulated value in a fluent way.

See Also
GetValue(String)

SelectField(String, Object, eSubTotalFunctions)

Specifies which value to use for a field.

Declaration
public ExcelPivotTableCalculatedData SelectField(string fieldName, object value, eSubTotalFunctions subtotalFunction)
Parameters
Type Name Description
System.String fieldName

The name of the field

System.Object value

The value

eSubTotalFunctions subtotalFunction
Returns
Type Description
ExcelPivotTableCalculatedData
In This Article
Back to top Generated by DocFX