SpreadJS Documentation
cellType Field
Indicates the cell type.
Syntax
var instance = new GcSpread.Sheets.Style(backColor,
                                        foreColor,
                                        hAlign,
                                        vAlign,
                                        font,
                                        themeFont,
                                        formatter,
                                        borderLeft,
                                        borderTop,
                                        borderRight,
                                        borderBottom,
                                        locked,
                                        textIndent,
                                        wordWrap,
                                        shrinkToFit,
                                        backgroundImage,
                                        cellType,
                                        backgroundImageLayout,
                                        tabStop,
                                        textDecoration,
                                        imeMode,
                                        name,
                                        parentName,
                                        watermark);
var value; // Type: BaseCellType
value = instance.cellType;
var cellType : BaseCellType;
Example
This example creates a style and applies it to a cell.
var cellType = new GcSpread.Sheets.ButtonCellType();
cellType.buttonBackColor("#FFFF00");
cellType.text("this is a button");
var style = new GcSpread.Sheets.Style();
style.backColor = "red";
style.borderLeft =new GcSpread.Sheets.LineBorder("blue");
style.borderTop = new GcSpread.Sheets.LineBorder("blue");
style.borderRight = new GcSpread.Sheets.LineBorder("blue");
style.borderBottom = new GcSpread.Sheets.LineBorder("blue");
style.cellType = cellType
activeSheet.setStyle(1,1,style,GcSpread.Sheets.SheetArea.viewport);
See Also

Reference

Style class

 

 


Copyright © GrapeCity, inc. All rights reserved.

Send comments on this topic.