【发布时间】:2021-10-03 19:40:42
【问题描述】:
当用户插入行(在谷歌表格中)并获取新创建的行号列表时,我使用谷歌脚本来捕获事件。
我试过 onChange :
function onInsertRow(e){
if (e.changeType == "INSERT_ROW") {
SpreadsheetApp.getUi().alert("insert");
}
}
触发器有效,但 onChange() 的事件对象没有范围属性。那么如何获取已插入的行号列表呢?
【问题讨论】:
标签: google-apps-script google-sheets triggers event-handling