Just wondering if there is a way to Pause script?
function test() {
for (var c = 1; c < 6 ; c++) {
var d = 'A'+c;
var value = SpreadsheetApp.getActiveSheet().getRange(d).getValue();
var valuep = valuep + "\\n"+ value ;
Browser.msgBox(valuep);
*** wait for "=>" key ***
}
}
You can add Utilities.sleep(time_in_ms)
to pause the execution of a Google Script.
Browser.msgBox
automatically pauses server side script execution. As written in the official documentation ,
Note that this method causes the server-side script to be suspended.
To handle a pressed key event, no. Apps Script doesn't have a console to input. – @Jescanellas
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.