SpreadJS 14
GC.Spread.Sheets Namespace / Commands type / renameSheet Field
In This Topic
    renameSheet Field
    In This Topic
    Represents the command used to rename a worksheet.
    Syntax
    var value; // Type: renameSheet
    value = GC.Spread.Sheets.Commands.renameSheet;
    var renameSheet : renameSheet;
    Example
    This example renames a sheet.
    spread.commandManager().execute({cmd: "renameSheet", sheetName: "Sheet1", name: "SheetName"});
    Remarks
    Name Description

    canUndo

    boolean

    Indicates whether the command supports undo and redo operations.

    execute

    function

    Performs an execute or undo function.

    The arguments of the execute method are as follows.

    • context {GC.Spread.Sheets.Workbook} - The context of the operation.
    • options {Object} - The options of the operation.
    • options.sheetName {string} - The sheet name.
    • options.index {number} - The outline starting index.
    • options.count {number} - The number of rows or columns to group or ungroup in the outline.
    • isUndo {boolean} - true if this is an undo operation; otherwise, false.
    See Also

    Reference

    Commands type