Class
ExcelPivotDataField
OfficeIMO.Excel
Describes a data field in a pivot table (field name + aggregation).
Inheritance
- object
- ExcelPivotDataField
Usage
Explore 1 API references to this type
This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.
Returned or exposed by 1
- Property ExcelPivotTableOptions.DataFields
Constructors
ExcelPivotDataField 2 overloads
public ExcelPivotDataField(string fieldName, ExcelPivotDataFunction? function, string? displayName, uint? numberFormatId) #Creates a pivot data field definition.
Parameters
- fieldName string
- Header name from the source range.
- function OfficeIMO.Excel.ExcelPivotDataFunction?
- Aggregation function (Sum, Count, Average, ...).
- displayName string?
- Optional display name for the data field.
- numberFormatId uint?
- Optional number format id to apply to the data field.
public ExcelPivotDataField(string fieldName, ExcelPivotDataFunction? function = null, string? displayName = null, uint? numberFormatId = null, string? numberFormat = null, ExcelPivotShowDataAs? showDataAs = null, int? baseField = null, uint? baseItem = null) #Creates a pivot data field definition.
Parameters
- fieldName string
- Header name from the source range.
- function OfficeIMO.Excel.ExcelPivotDataFunction? = null
- Aggregation function (Sum, Count, Average, ...).
- displayName string? = null
- Optional display name for the data field.
- numberFormatId uint? = null
- Optional number format id to apply to the data field.
- numberFormat string? = null
- Optional number format code to apply to the data field.
- showDataAs OfficeIMO.Excel.ExcelPivotShowDataAs? = null
- Optional show-values-as calculation mode.
- baseField int? = null
- Optional base field index for show-values-as calculations that require one.
- baseItem uint? = null
- Optional base item index for show-values-as calculations that require one.
Inherited Methods
Properties
public ExcelPivotDataFunction Function { get; } #Gets the aggregation function.
public string? DisplayName { get; } #Gets the optional display name for the data field.
public uint? 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 ExcelPivotShowDataAs? ShowDataAs { get; } #Gets the optional show-values-as calculation mode.
public int? BaseField { get; } #Gets the optional base field index for show-values-as calculations that require one.
public uint? BaseItem { get; } #Gets the optional base item index for show-values-as calculations that require one.