API Reference
Class
ExcelPivotDataField
Describes a data field in a pivot table (field name + aggregation).
Inheritance
- Object
- ExcelPivotDataField
Usage
This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.
Accepted by parameters
- Method ExcelSheet.AddPivotTable
- Method ExcelSheet.AddPivotTable
Constructors
ExcelPivotDataField 2 overloads
public ExcelPivotDataField(String fieldName, Nullable<DataConsolidateFunctionValues> function, String displayName, Nullable<UInt32> numberFormatId) #Creates a pivot data field definition.
Parameters
- fieldName System.String
- Header name from the source range.
- function System.Nullable{DocumentFormat.OpenXml.Spreadsheet.DataConsolidateFunctionValues}
- Aggregation function (Sum, Count, Average, ...).
- displayName System.String
- Optional display name for the data field.
- numberFormatId System.Nullable{System.UInt32}
- Optional number format id to apply to the data field.
public ExcelPivotDataField(String fieldName, Nullable<DataConsolidateFunctionValues> function = null, String displayName = null, Nullable<UInt32> numberFormatId = null, String numberFormat = null, Nullable<ShowDataAsValues> showDataAs = null, Nullable<Int32> baseField = null, Nullable<UInt32> baseItem = null) #Creates a pivot data field definition.
Parameters
- fieldName System.String
- Header name from the source range.
- function System.Nullable{DocumentFormat.OpenXml.Spreadsheet.DataConsolidateFunctionValues} = null
- Aggregation function (Sum, Count, Average, ...).
- displayName System.String = null
- Optional display name for the data field.
- numberFormatId System.Nullable{System.UInt32} = null
- Optional number format id to apply to the data field.
- numberFormat System.String = null
- Optional number format code to apply to the data field.
- showDataAs System.Nullable{DocumentFormat.OpenXml.Spreadsheet.ShowDataAsValues} = null
- Optional show-values-as calculation mode.
- baseField System.Nullable{System.Int32} = null
- Optional base field index for show-values-as calculations that require one.
- baseItem System.Nullable{System.UInt32} = null
- Optional base item index for show-values-as calculations that require one.
Inherited Methods
public override Boolean Equals(Object obj) #Returns:
BooleanInherited from Object
Parameters
- obj Object
Properties
public String FieldName { get; } #Gets the source field name.
public DataConsolidateFunctionValues Function { get; } #Gets the aggregation function.
public String DisplayName { get; } #Gets the optional display name for the data field.
public Nullable<UInt32> NumberFormatId { get; } #Gets the optional number format id for the data field.
public String NumberFormat { get; } #Gets the optional number format code for the data field.
public Nullable<ShowDataAsValues> ShowDataAs { get; } #Gets the optional show-values-as calculation mode.
public Nullable<Int32> BaseField { get; } #Gets the optional base field index for show-values-as calculations that require one.
public Nullable<UInt32> BaseItem { get; } #Gets the optional base item index for show-values-as calculations that require one.