fires before changing the currently active sheet

boolean BeforeSheetChange(object sheet){ ... };


sheetobjectthe object of the currently active sheet


booleantrue to change the active sheet, false to prevent the active sheet from being changed

Example"beforeSheetChange", function(sheet) {
    console.log("The active sheet will be changed" );
    return true;


The sheet object contains the following parameters:

  • name - (string) the name of the currently active sheet
  • id - (string) the id of the sheet

The event is blockable, returning false will prevent changing of the active sheet.

Change log

added in v4.1

Back to top