Launch Google Apps Script for Google-Spreadsheet event?

If I create a script for Google applications, can I connect it to a Google spreadsheet to trigger event-based or should I call it manually?

I don’t know if Google Sheets supports any events.

For example: a Google application script that crosses out rows in a spreadsheet that are marked completed by using a column with the number 1 next to the completed rows. I would like this to run whenever the row is modified, or even when the spreadsheet is loaded for the first time.

+3
source share
1 answer

The function is onOpen()automatically executed every time a table is loaded. In the future, we will disclose a common event API, but until then you can simply define your own function while it is called onOpen().
From Section 2 Tutorial

There is also a feature onEdit()that can be viewed at:

http://www.google.com/support/forum/p/apps-script/thread?tid=584a17c79e4c04d5&hl=en

It seems that handling events on the move depends on the security issues that are being developed.

+3
source

Source: https://habr.com/ru/post/1737614/


All Articles