[]
        
(Showing Draft Content)

GrapeCity.Documents.Excel.ISlicerItems

ISlicerItems Interface

Represents a collection of ISlicerItem objects in an ISlicerCache.

This interface provides access to all items currently stored in a slicer cache and supports indexed access, name-based access, and iteration.

Namespace: GrapeCity.Documents.Excel
Assembly: DS.Documents.Excel.dll
Syntax
public interface ISlicerItems : IEnumerable
Public Interface ISlicerItems
    Inherits IEnumerable
Examples
worksheet.Range["A1:B4"].Value = new object[,] {
    {"Category", "Amount"},
    {"Fruit", 100},
    {"Drink", 200},
    {"Fruit", 150}
};
ITable table = worksheet.Tables.Add(worksheet.Range["A1:B4"], true);
ISlicerCache slicerCache = workbook.SlicerCaches.Add(table, "Category");
ISlicerItems slicerItems = slicerCache.SlicerItems;
ISlicerItem slicerItem = slicerItems["Fruit"];

Properties

Name Description
Count

Gets the number of ISlicerItem objects in this collection.

This collection contains the slicer items associated with a ISlicerCache.

this[int]

Gets the ISlicerItem with the specified index.

this[string]

Gets the ISlicerItem with the specified name.

Use this property to retrieve a slicer item from the collection by its item name.