Hit trigger limit for scheduling - Apps Script solution?

497 views
Skip to first unread message

Andrew Davies

unread,
Aug 9, 2015, 7:39:39 PM8/9/15
to google-analytics-spreadsheet-add-on
Hey all,

I have a bunch of reports I run monthly and I've been scheduling them all using triggers (3rd day of the month at 4am). Probably 90% of my triggers are set to this and I've now hit a limit for the number of triggers I can have, but of course I've still got more reports to set up!

Does anyone know how I can move this trigger to being part of a library, which can still reference the reports I've set up in this add-on? 

I think the Google Apps Script I need is something like this:

ScriptApp.newTrigger("something-goes-here")
 
.timeBased()
 
.atHour(4)
 
.onMonthDay(3)
 
.create();

But I need to know what I should actually be referencing for it to refresh...

Philip Walton

unread,
Aug 10, 2015, 1:05:32 PM8/10/15
to Andrew Davies, google-analytics-spreadsheet-add-on
Hey Andrew, it sounds like you're writing your triggers manually in code and not using the scheduling in this add-on.

If that's the case I'd recommend asking this question on Stack Overflow or in a forum the Apps Scripts teams manages because you'd probably get a better answer.

FWIW, this add-on only uses a single trigger for all reports. You could try that strategy. You don't need separate triggers if they're all running at the same time.



--
You received this message because you are subscribed to the Google Groups "google-analytics-spreadsheet-add-on" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-analytics-spread...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-analytics-spreadsheet-add-on/d8f66397-ae7a-48ea-ab66-716fe4a1296b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Andrew Davies

unread,
Aug 10, 2015, 5:49:52 PM8/10/15
to Philip Walton, google-analytics-spreadsheet-add-on

Hi Philip,

Unfortunately I came across this limit / error within the add-on and I've only started looking at a scripted solution since I can't seem to find any other way to get around it.

I've looked at the triggers and as I said, most of them are actually copies of each other.

Just to clarify, they're different documents which have the duplicate triggers, but I seem to have hit a limit for myself as a user. I can't set up new triggers using this add-on in any Sheets file. :(

Philip Walton

unread,
Aug 10, 2015, 7:06:30 PM8/10/15
to Andrew Davies, google-analytics-spreadsheet-add-on

Andrew Davies

unread,
Aug 10, 2015, 7:42:13 PM8/10/15
to Philip Walton, google-analytics-spreadsheet-add-on
I did read that, but it doesn't sound like my problem.

I might just delete all of my triggers and start again... 

At this stage I think I might have to ditch the add-on and script from the ground-up. 
Reply all
Reply to author
Forward
0 new messages