API Reference

Class

ExcelPivotFieldOptions

Namespace OfficeIMO.Excel
Assembly OfficeIMO.Excel
Modifiers sealed

Describes formatting and display options for a pivot source field.

Inheritance

  • Object
  • ExcelPivotFieldOptions

Usage

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

Accepted by parameters

Constructors

public ExcelPivotFieldOptions(String fieldName, Nullable<FieldSortValues> sortType = null, Nullable<UInt32> numberFormatId = null, String numberFormat = null, Nullable<Boolean> showAll = null, Nullable<Boolean> defaultSubtotal = null, Nullable<Boolean> subtotalTop = null, Nullable<Boolean> insertBlankRow = null, Nullable<Boolean> insertPageBreak = null, Nullable<Boolean> compact = null, Nullable<Boolean> outline = null, Nullable<Boolean> showDropDowns = null, Nullable<Boolean> multipleItemSelectionAllowed = null, Nullable<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 requiredposition: 0
Header name from the source range.
sortType System.Nullable{DocumentFormat.OpenXml.Spreadsheet.FieldSortValues} = null optionalposition: 1
Optional pivot field sort mode.
numberFormatId System.Nullable{System.UInt32} = null optionalposition: 2
Optional number format id to apply to the pivot field.
numberFormat System.String = null optionalposition: 3
Optional number format code to apply to the pivot field.
showAll System.Nullable{System.Boolean} = null optionalposition: 4
Whether to show all items for the pivot field.
defaultSubtotal System.Nullable{System.Boolean} = null optionalposition: 5
Whether to use the default subtotal for the pivot field.
subtotalTop System.Nullable{System.Boolean} = null optionalposition: 6
Whether subtotals should be shown at the top.
insertBlankRow System.Nullable{System.Boolean} = null optionalposition: 7
Whether to insert a blank row after each item.
insertPageBreak System.Nullable{System.Boolean} = null optionalposition: 8
Whether to insert a page break after each item.
compact System.Nullable{System.Boolean} = null optionalposition: 9
Whether compact layout is enabled for this field.
outline System.Nullable{System.Boolean} = null optionalposition: 10
Whether outline layout is enabled for this field.
showDropDowns System.Nullable{System.Boolean} = null optionalposition: 11
Whether field drop-downs are shown.
multipleItemSelectionAllowed System.Nullable{System.Boolean} = null optionalposition: 12
Whether multiple filter item selection is allowed.
includeNewItemsInFilter System.Nullable{System.Boolean} = null optionalposition: 13
Whether new source items are included in the filter by default.
subtotalCaption System.String = null optionalposition: 14
Optional custom subtotal caption.
hiddenItems System.Collections.Generic.IEnumerable{System.String} = null optionalposition: 15
Optional source item captions to hide.
visibleItems System.Collections.Generic.IEnumerable{System.String} = null optionalposition: 16
Optional source item captions to show; other known items are hidden.
selectedItem System.String = null optionalposition: 17
Optional page-field item caption to select.

Methods

public static ExcelPivotFieldOptions HideItems(String fieldName, params String[] items) #
Returns: ExcelPivotFieldOptions

Creates field options that hide the specified source item captions.

Parameters

fieldName System.String requiredposition: 0
items System.String[] requiredposition: 1
public static ExcelPivotFieldOptions SelectPageItem(String fieldName, String item) #
Returns: ExcelPivotFieldOptions

Creates field options that select an item for a page/filter field.

Parameters

fieldName System.String requiredposition: 0
item System.String requiredposition: 1
public static ExcelPivotFieldOptions ShowOnlyItems(String fieldName, params String[] items) #
Returns: ExcelPivotFieldOptions

Creates field options that show only the specified source item captions.

Parameters

fieldName System.String requiredposition: 0
items System.String[] requiredposition: 1

Properties

public String FieldName { get; } #

Gets the source field name.

public Nullable<FieldSortValues> SortType { get; } #

Gets the optional pivot field sort mode.

public Nullable<UInt32> NumberFormatId { get; } #

Gets the optional number format id.

public String NumberFormat { get; } #

Gets the optional number format code.

public Nullable<Boolean> ShowAll { get; } #

Gets whether all items should be shown for the field.

public Nullable<Boolean> DefaultSubtotal { get; } #

Gets whether the default subtotal should be used.

public Nullable<Boolean> SubtotalTop { get; } #

Gets whether subtotals should be shown at the top.

public Nullable<Boolean> InsertBlankRow { get; } #

Gets whether to insert a blank row after each item.

public Nullable<Boolean> InsertPageBreak { get; } #

Gets whether to insert a page break after each item.

public Nullable<Boolean> Compact { get; } #

Gets whether compact layout is enabled for this field.

public Nullable<Boolean> Outline { get; } #

Gets whether outline layout is enabled for this field.

public Nullable<Boolean> ShowDropDowns { get; } #

Gets whether field drop-downs are shown.

public Nullable<Boolean> MultipleItemSelectionAllowed { get; } #

Gets whether multiple item selection is allowed.

public Nullable<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> HiddenItems { get; } #

Gets source item captions to hide.

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.