var instance = new GC.Spread.Sheets.Slicers.ItemSlicer(name, slicerData, columnName);
function ItemSlicer;
var instance = new GC.Spread.Sheets.Slicers.ItemSlicer(name, slicerData, columnName);
function ItemSlicer;
//This example creates an item slicer. //create table var dataSource = [ { Name: "Bob", City: "NewYork", Birthday: "1968/6/8" }, { Name: "Betty", City: "NewYork", Birthday: "1972/7/3" }, { Name: "Alice", City: "Washington", Birthday: "2012/2/15" }, ]; var table = activeSheet.tables.addFromDataSource("table1", 1, 1, dataSource); var slicerData = new GC.Spread.Sheets.Slicers.TableSlicerData(table) //Set slicer data to item slicer. var slicer = new GC.Spread.Sheets.Slicers.ItemSlicer("slicer", slicerData, "Name"); //Add the item slicer to the dom tree. //The "slicerHost" is the div you want to add the slicer's dom to. $("#slicerHost").append(slicer.getDOMElement());
Object
GC.Spread.Sheets.Slicers.ItemSlicer
Name | Description | |
---|---|---|
ItemSlicer Constructor | Represents an item slicer. |
Name | Description | |
---|---|---|
captionName | Gets or sets the caption name of the item slicer. | |
columnCount | Gets or sets the column count of the item slicer. | |
getDOMElement | Gets the dom element of the item slicer. | |
height | Gets or sets the height of the item slicer. | |
itemHeight | Gets or sets the item height of the item slicer. | |
name | Gets or sets the name of the item slicer. | |
showHeader | Gets or sets whether to show the header of the item slicer. | |
showNoDataItems | Gets or sets whether to show the no data items of the item slicer. | |
showNoDataItemsInLast | Gets or sets whether to show the no data items last. | |
sortState | Gets or sets the sort state of the item slicer. | |
style | Gets or sets the style of the item slicer. | |
visuallyNoDataItems | Gets or sets whether to visually distinguish the items with no data. | |
width | Gets or sets the width of the item slicer. |