API Reference
ExcelPivotFieldOptions
Describes formatting and display options for a pivot source field.
Inheritance
- Object
- ExcelPivotFieldOptions
Usage
Explore 5 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 3
Accepted by parameters 2
- Method ExcelSheet.AddPivotTable
- Method PivotTableBuilder.FieldOptions
Constructors
public ExcelPivotFieldOptions(String fieldName, ExcelPivotFieldSort? sortType = null, UInt32? numberFormatId = null, String? numberFormat = null, Boolean? showAll = null, Boolean? defaultSubtotal = null, Boolean? subtotalTop = null, Boolean? insertBlankRow = null, Boolean? insertPageBreak = null, Boolean? compact = null, Boolean? outline = null, Boolean? showDropDowns = null, Boolean? multipleItemSelectionAllowed = null, Boolean? includeNewItemsInFilter = null, String? subtotalCaption = null, IEnumerable<String>? hiddenItems = null, IEnumerable<String>? visibleItems = null, String? selectedItem = null) #Creates pivot field options for a source field.
Parameters
- fieldName System.String
- Header name from the source range.
- sortType OfficeIMO.Excel.ExcelPivotFieldSort? = null
- Optional pivot field sort mode.
- numberFormatId System.UInt32? = null
- Optional number format id to apply to the pivot field.
- numberFormat System.String? = null
- Optional number format code to apply to the pivot field.
- showAll System.Boolean? = null
- Whether to show all items for the pivot field.
- defaultSubtotal System.Boolean? = null
- Whether to use the default subtotal for the pivot field.
- subtotalTop System.Boolean? = null
- Whether subtotals should be shown at the top.
- insertBlankRow System.Boolean? = null
- Whether to insert a blank row after each item.
- insertPageBreak System.Boolean? = null
- Whether to insert a page break after each item.
- compact System.Boolean? = null
- Whether compact layout is enabled for this field.
- outline System.Boolean? = null
- Whether outline layout is enabled for this field.
- showDropDowns System.Boolean? = null
- Whether field drop-downs are shown.
- multipleItemSelectionAllowed System.Boolean? = null
- Whether multiple filter item selection is allowed.
- includeNewItemsInFilter System.Boolean? = null
- Whether new source items are included in the filter by default.
- subtotalCaption System.String? = null
- Optional custom subtotal caption.
- hiddenItems System.Collections.Generic.IEnumerable<System.String>? = null
- Optional source item captions to hide.
- visibleItems System.Collections.Generic.IEnumerable<System.String>? = null
- Optional source item captions to show; other known items are hidden.
- selectedItem System.String? = null
- Optional page-field item caption to select.
Methods
public static ExcelPivotFieldOptions HideItems(String fieldName, params String[] items) #ExcelPivotFieldOptionsCreates field options that hide the specified source item captions.
Parameters
- fieldName System.String
- items System.String[]
public static ExcelPivotFieldOptions SelectPageItem(String fieldName, String item) #ExcelPivotFieldOptionsCreates field options that select an item for a page/filter field.
Parameters
- fieldName System.String
- item System.String
public static ExcelPivotFieldOptions ShowOnlyItems(String fieldName, params String[] items) #ExcelPivotFieldOptionsCreates field options that show only the specified source item captions.
Parameters
- fieldName System.String
- items System.String[]
Inherited Methods
public virtual Boolean Equals(Object? obj) #BooleanParameters
- obj Object?
Properties
public ExcelPivotFieldSort? SortType { get; } #Gets the optional pivot field sort mode.
public UInt32? NumberFormatId { get; } #Gets the optional number format id.
public String? NumberFormat { get; } #Gets the optional number format code.
public Boolean? ShowAll { get; } #Gets whether all items should be shown for the field.
public Boolean? DefaultSubtotal { get; } #Gets whether the default subtotal should be used.
public Boolean? SubtotalTop { get; } #Gets whether subtotals should be shown at the top.
public Boolean? InsertBlankRow { get; } #Gets whether to insert a blank row after each item.
public Boolean? InsertPageBreak { get; } #Gets whether to insert a page break after each item.
public Boolean? Compact { get; } #Gets whether compact layout is enabled for this field.
public Boolean? Outline { get; } #Gets whether outline layout is enabled for this field.
public Boolean? ShowDropDowns { get; } #Gets whether field drop-downs are shown.
public Boolean? MultipleItemSelectionAllowed { get; } #Gets whether multiple item selection is allowed.
public Boolean? IncludeNewItemsInFilter { get; } #Gets whether new source items are included in the filter by default.
public String? SubtotalCaption { get; } #Gets the optional custom subtotal caption.
public IReadOnlyList<String> VisibleItems { get; } #Gets source item captions to show; other known items are hidden.
public String? SelectedItem { get; } #Gets the selected page-field item caption.