Search code examples
google-apps-scriptgoogle-sheetsgoogle-workspacegoogle-apps-script-addon

Google sheets add on do not show menu items for all sheets


So I just published an Google Sheets add-on.

It shows the menu items for the first sheet. But as soon as I run some functions on that sheet, it only shows menu items on that sheet and not the other sheets in my drive.

I think that addon script is getting bound to the first sheet somehow.

Any ideas why it would be happening?


Solution

  • So the add-on was publically published. I figured it out. It was because of an error in the global variable declaration - activeSpreadsheet = SpreadsheetApp.getActiveSreadsheet();

    Your add-ons have a google console project associated with them. The console gives access to error reporting. I found this error on the console. I corrected the error and published it and now it is working fine.