Google Apps Script 50 Exercises Explained Vol 1

https://github.com/lsvekis/Apps-Script-Code-Examples 1) Add a Custom Menu on Open (Sheets) Does: Adds a menu to your spreadsheet UI.Use when: You want easy buttons for scripts. function onOpen() { SpreadsheetApp.getUi() .createMenu(‘Tools’) .addItem(‘Say Hello’, ‘sayHello’) .addSeparator() .addItem(‘Run Cleanup’, ‘cleanup’) .addToUi(); } function sayHello() { SpreadsheetApp.getUi().alert(‘Hello from Apps Script!’); } function cleanup() { SpreadsheetApp.getUi().alert(‘Cleanup placeholder.’); } 2) Show a ...