Skip to main content


fires before the style of cells is changed

beforeStyleChange: (cell: string, style: string | string[] | IStylesList | IStylesList[]) => void | boolean;


  • cell: string - the id(s) of a cell(s)
  • style: string, object, array - styles set for a cell/cells


True to change the style of a cell, false to prevent changing of style.

Example"beforeStyleChange", function(cell,style){
console.log("Style of cell "+spreadsheet.selection.getSelectedCell()+" will change");
return true;

The event is blockable, returning false will prevent changing of style.