From e759452b92b9a4f77c0e1bbcb5e4ade332672070 Mon Sep 17 00:00:00 2001 From: Ed Grosvenor Date: Wed, 11 Mar 2020 16:26:56 -0500 Subject: [PATCH] update readme --- README.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/README.md b/README.md index 17ca5dc..4b90972 100644 --- a/README.md +++ b/README.md @@ -59,6 +59,18 @@ php artisan make:sheet-model --- +You can use something like this to enable the macro generated on your sheet as an [installable trigger](https://developers.google.com/apps-script/guides/triggers/installable): + +```javascript +function createSpreadsheetOpenTrigger() { + var ss = SpreadsheetApp.getActive(); + ScriptApp.newTrigger('onEdit') + .forSpreadsheet(ss) + .onEdit() + .create(); +} +``` + ### The Resulting Model Class ```php