SpreadJS 13
GC.Spread.Sheets.CellTypes Namespace / HyperLink class / activeOnClick Method
Whether to move to the active cell when clicked.
In This Topic
    activeOnClick Method
    In This Topic
    Gets or sets whether to move to the active cell when clicked.
    Syntax
    var instance = new GC.Spread.Sheets.CellTypes.HyperLink();
    var returnValue; // Type: any
    returnValue = instance.activeOnClick(value);
    function activeOnClick( 
       value : boolean
    ) : any;

    Parameters

    value
    Whether to move to the active cell when clicked.

    Return Value

    If no value is set, returns a value that indicates whether to move to the active cell; otherwise, returns the hyperlink cell type.
    Example
    //This example uses the activeOnClick method.
    var h1 = new GC.Spread.Sheets.CellTypes.HyperLink();
    h1.text("GrapeCity");
    h1.linkToolTip("link to GrapeCity Web page");
    h1.linkColor("rgb(0, 100, 200)");
    h1.visitedLinkColor("rgb(0, 200, 100)");
    h1.activeOnClick(true);
    activeSheet.setCellType(1, 1, h1);
    activeSheet.getCell(1, 1, GC.Spread.Sheets.SheetArea.viewport).value("http://www.grapecity.com/").hAlign(GC.Spread.Sheets.HorizontalAlign.center);
    See Also

    Reference

    HyperLink class