UrlFetchApp.fetch() simply does not work in onEdit trigger

江枫思渺然 提交于 2019-12-01 03:24:07

Simple triggers like onOpen or onEdit are not able to do anything that requires authorization like sending mails because they run silently and anonymously. This is all explained in the documentation .

You should simply rename your onEdit function to something else - SpecialOnEdit for example ? - and create an installable trigger (documentation) from the script editor menu (ressources/triggers/create a new trigger...)

You can see an execution flow in view -> execution transcript in the script editor. Just change a cell value in spreadsheet then come back the script editor and check "execution transcript". It will show you an error if it happens.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!