SpreadJS 14
GC.Spread.Sheets Namespace / Commands type / clear Field
In This Topic
    clear Field
    In This Topic
    Represents the command used to clear the cell value.
    Syntax
    var value; // Type: clear
    value = GC.Spread.Sheets.Commands.clear;
    var clear : clear;
    Example
    This example uses the clear method.
    // clear selected cells with the tab key
    spread.commandManager().setShortcutKey('clear', GC.Spread.Commands.Key.tab, false, false, false, false); // Tab key
    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.
    • isUndo {boolean} - true if this is an undo operation; otherwise, false.
    See Also

    Reference

    Commands type