var instance = new GC.Spread.Sheets.Workbook(host, options, options.sheetCount, options.font, options.allowUserDragMerge, options.allowUserDragDrop, options.allowUserDragFill, options.allowUserZoom, options.allowUserResize, options.allowUndo, options.allowSheetReorder, options.allowContextMenu, options.allowUserDeselect, options.defaultDragFillType, options.showDragFillSmartTag, options.showHorizontalScrollbar, options.showVerticalScrollbar, options.scrollbarShowMax, options.scrollbarMaxAlign, options.tabStripVisible, options.tabStripRatio, options.tabEditable, options.newTabVisible, options.tabNavigationVisible, options.cutCopyIndicatorVisible, options.cutCopyIndicatorBorderColor, options.backColor, options.backgroundImage, options.backgroundImageLayout, options.grayAreaBackColor, options.showResizeTip, options.showDragDropTip, options.showDragFillTip, options.showScrollTip, options.scrollIgnoreHidden, options.highlightInvalidData, options.useTouchLayout, options.hideSelection, options.resizeZeroIndicator, options.allowUserEditFormula, options.enableFormulaTextbox, options.autoFitType, options.referenceStyle, options.calcOnDemand, options.allowCopyPasteExcelStyle, options.allowExtendPasteRange, options.copyPasteHeaderOptions, options.scrollByPixel, options.scrollPixel, options.customList);
function Workbook( host : Object, (optional) options : Object, (optional) options.sheetCount : number, (optional) options.font : string, (optional) options.allowUserDragMerge : boolean, (optional) options.allowUserDragDrop : boolean, (optional) options.allowUserDragFill : boolean, (optional) options.allowUserZoom : boolean, (optional) options.allowUserResize : boolean, (optional) options.allowUndo : boolean, (optional) options.allowSheetReorder : boolean, (optional) options.allowContextMenu : boolean, (optional) options.allowUserDeselect : boolean, (optional) options.defaultDragFillType : AutoFillType, (optional) options.showDragFillSmartTag : boolean, (optional) options.showHorizontalScrollbar : boolean, (optional) options.showVerticalScrollbar : boolean, (optional) options.scrollbarShowMax : boolean, (optional) options.scrollbarMaxAlign : boolean, (optional) options.tabStripVisible : boolean, (optional) options.tabStripRatio : number, (optional) options.tabEditable : boolean, (optional) options.newTabVisible : boolean, (optional) options.tabNavigationVisible : boolean, (optional) options.cutCopyIndicatorVisible : boolean, (optional) options.cutCopyIndicatorBorderColor : string, (optional) options.backColor : string, (optional) options.backgroundImage : string, (optional) options.backgroundImageLayout : ImageLayout, (optional) options.grayAreaBackColor : string, (optional) options.showResizeTip : ShowResizeTip, (optional) options.showDragDropTip : boolean, (optional) options.showDragFillTip : boolean, (optional) options.showScrollTip : ShowScrollTip, (optional) options.scrollIgnoreHidden : boolean, (optional) options.highlightInvalidData : boolean, (optional) options.useTouchLayout : boolean, (optional) options.hideSelection : boolean, (optional) options.resizeZeroIndicator : ResizeZeroIndicator, (optional) options.allowUserEditFormula : boolean, (optional) options.enableFormulaTextbox : boolean, (optional) options.autoFitType : AutoFitType, (optional) options.referenceStyle : ReferenceStyle, (optional) options.calcOnDemand : boolean, (optional) options.allowCopyPasteExcelStyle : boolean, (optional) options.allowExtendPasteRange : boolean, (optional) options.copyPasteHeaderOptions : CopyPasteHeaderOptions, (optional) options.scrollByPixel : boolean, (optional) options.scrollPixel : number, (optional) options.customList : Array ) : Workbook;
Parameters
- host
- The host DOM element.
- options
- The initialization options.
- options.sheetCount
- The number of sheets.
- options.font
- The tab strip font.
- options.allowUserDragMerge
- Whether to allow the user to drag merge cells.
- options.allowUserDragDrop
- Whether to allow the user to drag and drop range data.
- options.allowUserDragFill
- Whether to allow the user to drag fill a range.
- options.allowUserZoom
- Whether to zoom the display by scrolling the mouse wheel while pressing the Ctrl key.
- options.allowUserResize
- Whether to allow the user to resize columns and rows.
- options.allowUndo
- Whether to allow the user to undo edits.
- options.allowSheetReorder
- Whether the user can reorder the sheets in the Spread component.
- options.allowContextMenu
- Whether to allow the user to open the built-in context menu.
- options.allowUserDeselect
- Whether to allow the user to can use deselect in selection.
- options.defaultDragFillType
- The default fill type.
- options.showDragFillSmartTag
- Whether to display the drag fill dialog.
- options.showHorizontalScrollbar
- Whether to display the horizontal scroll bar.
- options.showVerticalScrollbar
- Whether to display the vertical scroll bar.
- options.scrollbarShowMax
- Whether the displayed scroll bars are based on the entire number of columns and rows in the sheet.
- options.scrollbarMaxAlign
- Whether the scroll bar aligns with the last row and column of the active sheet.
- options.tabStripVisible
- Whether to display the sheet tab strip.
- options.tabStripRatio
- The width of the tab strip expressed as a percentage of the overall horizontal scroll bar width.
- options.tabEditable
- Whether to allow the user to edit the sheet tab strip.
- options.newTabVisible
- Whether the spreadsheet displays the special tab to let users insert new sheets.
- options.tabNavigationVisible
- Whether to display the sheet tab navigation.
- options.cutCopyIndicatorVisible
- Whether to display an indicator when copying or cutting the selected item.
- options.cutCopyIndicatorBorderColor
- The border color for the indicator displayed when the user cuts or copies the selection.
- options.backColor
- A color string used to represent the background color of the Spread component, such as "red", "#FFFF00", "rgb(255,0,0)", "Accent 5", and so on.
- options.backgroundImage
- The background image of the Spread component.
- options.backgroundImageLayout
- The background image layout for the Spread component.
- options.grayAreaBackColor
- A color string used to represent the background color of the gray area , such as "red", "#FFFF00", "rgb(255,0,0)", "Accent 5", and so on.
- options.showResizeTip
- How to display the resize tip.
- options.showDragDropTip
- -Whether to display the drag-drop tip.
- options.showDragFillTip
- Whether to display the drag-fill tip.
- options.showScrollTip
- How to display the scroll tip.
- options.scrollIgnoreHidden
- Whether the scroll bar ignores hidden rows or columns.
- options.highlightInvalidData
- Whether to highlight invalid data.
- options.useTouchLayout
- Whether to use touch layout to present the Spread component.
- options.hideSelection
- Whether to display the selection highlighting when the Spread component does not have focus.
- options.resizeZeroIndicator
- The drawing policy when the row or column is resized to zero.
- options.allowUserEditFormula
- Whether the user can edit formulas in a cell in the spreadsheet.
- options.enableFormulaTextbox
- Whether to enable the formula text box in the spreadsheet.
- options.autoFitType
- Whether content will be formatted to fit in cells or in cells and headers.
- options.referenceStyle
- the style for cell and range references in cell formulas on this sheet.
- options.calcOnDemand
- Whether to calculate formulas only when they are demanded.
- options.allowCopyPasteExcelStyle
- Whether the user can copy style from Spread Sheets then paste to Excel, or copy style from Excel then paste to Spread Sheets.
- options.allowExtendPasteRange
- Whether extend paste range if the paste range is not enough for pasting.
- options.copyPasteHeaderOptions
- Which headers are included when data is copied to or pasted.
- options.scrollByPixel
- Whether to enable the precision scrolling by pixel.
- options.scrollPixel
- Decides scrolling by that number of pixels at a time when scrollByPixel is true. The final scrolling pixels are the result of scrolling delta multiply scrollPixel. For example, the scrolling delta is 3, and the scrollPixel is 5, the final scrolling pixels are 15.
- options.customList
- The list for user to customize drag fill, prioritize matching this list in each fill. Each array item is type of string array.