[]
        
(Showing Draft Content)

GrapeCity.Documents.Excel.Drawing.IPivotOptions

IPivotOptions Interface

Represents the display options for PivotChart field buttons.

Use this interface to control whether report filter, legend, axis, value, and other field buttons are shown on a PivotChart. Obtain an IPivotOptions object from PivotOptions.

Namespace: GrapeCity.Documents.Excel.Drawing
Assembly: DS.Documents.Excel.dll
Syntax
public interface IPivotOptions
Public Interface IPivotOptions
Examples
worksheet.Range["A1:B4"].Value = new object[,] {
    {"Category", "Amount"},
    {"Fruit", 100},
    {"Fruit", 200},
    {"Vegetable", 150}
};
IPivotCache pivotCache = workbook.PivotCaches.Create(worksheet.Range["A1:B4"]);
IPivotTable pivotTable = worksheet.PivotTables.Add(pivotCache, worksheet.Range["D1"]);
pivotTable.PivotFields["Category"].Orientation = PivotFieldOrientation.RowField;
pivotTable.PivotFields["Amount"].Orientation = PivotFieldOrientation.DataField;
IChart chart = worksheet.Shapes.AddChart(ChartType.ColumnClustered, 10, 10, 300, 200).Chart;
chart.SeriesCollection.Add(pivotTable.TableRange1);
IPivotOptions pivotOptions = chart.PivotOptions;
pivotOptions.ShowLegendFieldButtons = false;

Properties

Name Description
ShowAllFieldButtons

Gets or sets whether all field buttons are displayed on a PivotChart.

Field buttons include the interactive buttons shown on a PivotChart for filtering and expanding PivotTable fields.

ShowAxisFieldButtons

Gets or sets whether the axis field buttons are displayed on a PivotChart.

ShowExpandCollapseEntireFieldButtons

Gets or sets whether the expand entire field and collapse entire field buttons are displayed on a PivotChart.

These buttons let users expand or collapse an entire field directly from the PivotChart.

ShowLegendFieldButtons

Gets or sets whether legend field buttons are displayed on a PivotChart.

Use this property to determine the current visibility of legend field buttons for a PivotChart's PivotOptions settings.

ShowReportFilterFieldButtons

Gets or sets whether the report filter field buttons are displayed on a PivotChart.

ShowValueFieldButtons

Gets or sets whether value field buttons are displayed on a PivotChart.

This property returns the current visibility setting for value field buttons in the PivotOptions object of a PivotChart.