SpreadJS Documentation
ItemSlicer type
GC.Spread.Sheets.Slicers Namespace : ItemSlicer type
Represents an item slicer.
Syntax
var instance = new GC.Spread.Sheets.Slicers.ItemSlicer(name, slicerData, columnName);
function ItemSlicer;
Example
//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());
Inheritance Hierarchy

Object
   GC.Spread.Sheets.Slicers.ItemSlicer

Constructors
 NameDescription
public ConstructorRepresents an item slicer.  
Top
Methods
 NameDescription
public MethodGets or sets the caption name of the item slicer.  
public MethodGets or sets the column count of the item slicer.  
public MethodGets the dom element of the item slicer.  
public MethodGets or sets the height of the item slicer.  
public MethodGets or sets the item height of the item slicer.  
public MethodGets or sets the name of the item slicer.  
public MethodGets or sets whether to show the header of the item slicer.  
public MethodGets or sets whether to show the no data items of the item slicer.  
public MethodGets or sets whether to show the no data items last.  
public MethodGets or sets the sort state of the item slicer.  
public MethodGets or sets the style of the item slicer.  
public MethodGets or sets whether to visually distinguish the items with no data.  
public MethodGets or sets the width of the item slicer.  
Top
See Also

Reference

GC.Spread.Sheets.Slicers Namespace