Reputation: 601
I'm making a database type thing where a sheet can write and compare to another sheet. The write is done with a script but the call back is achieved on the sheet with QUERY
. And as part of the script I am doing some formatting based on these return values.
The issue I have is if I write to the database spreadsheet and then run the formatting straight afterwards the sheet query has not executed in time. I tried using SpreadsheetApp.flush();
after the write command but it doesn't help and to be honest I'm not really sure what its supposed to do anyway.
Any help would be much appreciated
Upvotes: 0
Views: 45
Reputation: 386
I'm not sure if this is the most efficient answer, but you might be able to use Utilities.sleep(1000) to wait for 1 second after executing the first command.
Upvotes: 1