Backcolor change of existing button celltype

Posted by: amitha.thampy on 8 April 2021, 5:11 am EST

    • Post Options:
    • Link

    Posted 8 April 2021, 5:11 am EST

    Hi,

    Im not able to change backcolor of an existing button celltype(created in spreadjs designer) dynamically from code.

  • Posted 8 April 2021, 9:21 pm EST

    Hi,

    You may use buttonBackColor method for the required functionality. Please refer to the following code snippet and let us know if you face any issues.

    
    var cellType = new GC.Spread.Sheets.CellTypes.Button();
    cellType.buttonBackColor("#FFFF00");
    cellType.text("this is a button");
    activeSheet.getCell(0, 2).cellType(cellType);
    
    

    buttonBackColor: https://www.grapecity.com/spreadjs/docs/v14/online/SpreadJS~GC.Spread.Sheets.CellTypes.Button~buttonBackColor.html

    Regards

    Avinash

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels