Skip to main content
edited tags
Link
added 9 characters in body
Source Link
pnuts
  • 17.8k
  • 5
  • 54
  • 103

I have a Google spreadsheet consisting of different months on each tab. Every month, I add a new tab and another 50-75 rows. There are many tabs. There is a cell on each row which calls a custom function, like this:

=myFunction(A1)

The problem that I am having is that I am getting the following error:

error: Script invoked too many times per second for this Google user account.

error: Script invoked too many times per second for this Google user account.

What can I do to prevent this error from occurring? Is

Is the problem because there are too many tabs, or too many rows per tab?

There must be a way to prevent the function from having to run more than once. Thanks.

 

Here is a shortened version of the function that is called:

function myFunction(expense) {
if (
  InStr(1,expense,"CPC SCP") ||
  InStr(1,expense,"CPC/SCP") ||
  InStr(1,expense,"xxxx")
  )
  { category = "5530 - Postage Expense" } 
 
  else if (
  InStr(1,expense,"PRE-AUTHORIZED PAYMENT") ||
  InStr(1,expense,"xxx ")
  )
  { category = "9999 - Payment" } 
  
  else if (
  InStr(1,expense,"PURCHASE INTEREST") ||
  InStr(1,expense,"RETURNED PAYMENT FEE") ||
  InStr(1,expense,"xxxx")
  )
  { category = "5070 - Bank Charges" } 

else { category = "Not Sure" }
    
return category;  

} 

I have a Google spreadsheet consisting of different months on each tab. Every month, I add a new tab and another 50-75 rows. There are many tabs. There is a cell on each row which calls a custom function, like this:

=myFunction(A1)

The problem that I am having is that I am getting the following error:

error: Script invoked too many times per second for this Google user account.

What can I do to prevent this error from occurring? Is the problem because there are too many tabs, or too many rows per tab?

There must be a way to prevent the function from having to run more than once. Thanks.

Here is a shortened version of the function that is called:

function myFunction(expense) {
if (
  InStr(1,expense,"CPC SCP") ||
  InStr(1,expense,"CPC/SCP") ||
  InStr(1,expense,"xxxx")
  )
  { category = "5530 - Postage Expense" } 
 
  else if (
  InStr(1,expense,"PRE-AUTHORIZED PAYMENT") ||
  InStr(1,expense,"xxx ")
  )
  { category = "9999 - Payment" } 
  
  else if (
  InStr(1,expense,"PURCHASE INTEREST") ||
  InStr(1,expense,"RETURNED PAYMENT FEE") ||
  InStr(1,expense,"xxxx")
  )
  { category = "5070 - Bank Charges" } 

else { category = "Not Sure" }
    
return category;  

} 

I have a Google spreadsheet consisting of different months on each tab. Every month, I add a new tab and another 50-75 rows. There are many tabs. There is a cell on each row which calls a custom function, like this:

=myFunction(A1)

The problem I am having is that I am getting the following error:

error: Script invoked too many times per second for this Google user account.

What can I do to prevent this error from occurring?

Is the problem because there are too many tabs, or too many rows per tab?

There must be a way to prevent the function from having to run more than once.

 

Here is a shortened version of the function that is called:

function myFunction(expense) {
if (
  InStr(1,expense,"CPC SCP") ||
  InStr(1,expense,"CPC/SCP") ||
  InStr(1,expense,"xxxx")
  )
  { category = "5530 - Postage Expense" } 
 
  else if (
  InStr(1,expense,"PRE-AUTHORIZED PAYMENT") ||
  InStr(1,expense,"xxx ")
  )
  { category = "9999 - Payment" } 
  
  else if (
  InStr(1,expense,"PURCHASE INTEREST") ||
  InStr(1,expense,"RETURNED PAYMENT FEE") ||
  InStr(1,expense,"xxxx")
  )
  { category = "5070 - Bank Charges" } 

else { category = "Not Sure" }
    
return category;  

} 
Tweeted twitter.com/#!/StackWebApps/status/462021122738110464
deleted 7 characters in body
Source Link
ale
  • 52.9k
  • 42
  • 165
  • 314

I have a googleGoogle spreadsheet consisting of different months on each tab. Every month, I add a new tab and another 50-75 rows. There are many tabs. There is a cell on each row which calls a custom function, like this:

=myFunction(A1)

The problem that I am having is that I am getting the following error:

error: Script invoked too many times per second for this Google user account.

What can I do to prevent this error from occurring? Is the problem because there are too many tabs, or too many rows per tab?

There must be a way to prevent the function from having to run more than once. Thanks.

EDIT: HereHere is a shortened version of the function that is called:

function myFunction(expense) {
if (
  InStr(1,expense,"CPC SCP") ||
  InStr(1,expense,"CPC/SCP") ||
  InStr(1,expense,"xxxx")
  )
  { category = "5530 - Postage Expense" } 
 
  else if (
  InStr(1,expense,"PRE-AUTHORIZED PAYMENT") ||
  InStr(1,expense,"xxx ")
  )
  { category = "9999 - Payment" } 
  
  else if (
  InStr(1,expense,"PURCHASE INTEREST") ||
  InStr(1,expense,"RETURNED PAYMENT FEE") ||
  InStr(1,expense,"xxxx")
  )
  { category = "5070 - Bank Charges" } 

else { category = "Not Sure" }
    
return category;  

} 

I have a google spreadsheet consisting of different months on each tab. Every month, I add a new tab and another 50-75 rows. There are many tabs. There is a cell on each row which calls a custom function, like this:

=myFunction(A1)

The problem that I am having is that I am getting the following error:

error: Script invoked too many times per second for this Google user account.

What can I do to prevent this error from occurring? Is the problem because there are too many tabs, or too many rows per tab?

There must be a way to prevent the function from having to run more than once. Thanks.

EDIT: Here is a shortened version of the function that is called:

function myFunction(expense) {
if (
  InStr(1,expense,"CPC SCP") ||
  InStr(1,expense,"CPC/SCP") ||
  InStr(1,expense,"xxxx")
  )
  { category = "5530 - Postage Expense" } 
 
  else if (
  InStr(1,expense,"PRE-AUTHORIZED PAYMENT") ||
  InStr(1,expense,"xxx ")
  )
  { category = "9999 - Payment" } 
  
  else if (
  InStr(1,expense,"PURCHASE INTEREST") ||
  InStr(1,expense,"RETURNED PAYMENT FEE") ||
  InStr(1,expense,"xxxx")
  )
  { category = "5070 - Bank Charges" } 

else { category = "Not Sure" }
    
return category;  

} 

I have a Google spreadsheet consisting of different months on each tab. Every month, I add a new tab and another 50-75 rows. There are many tabs. There is a cell on each row which calls a custom function, like this:

=myFunction(A1)

The problem that I am having is that I am getting the following error:

error: Script invoked too many times per second for this Google user account.

What can I do to prevent this error from occurring? Is the problem because there are too many tabs, or too many rows per tab?

There must be a way to prevent the function from having to run more than once. Thanks.

Here is a shortened version of the function that is called:

function myFunction(expense) {
if (
  InStr(1,expense,"CPC SCP") ||
  InStr(1,expense,"CPC/SCP") ||
  InStr(1,expense,"xxxx")
  )
  { category = "5530 - Postage Expense" } 
 
  else if (
  InStr(1,expense,"PRE-AUTHORIZED PAYMENT") ||
  InStr(1,expense,"xxx ")
  )
  { category = "9999 - Payment" } 
  
  else if (
  InStr(1,expense,"PURCHASE INTEREST") ||
  InStr(1,expense,"RETURNED PAYMENT FEE") ||
  InStr(1,expense,"xxxx")
  )
  { category = "5070 - Bank Charges" } 

else { category = "Not Sure" }
    
return category;  

} 
Added code
Source Link
Loading
retagging
Link
Jacob Jan
  • 23.3k
  • 16
  • 106
  • 195
Loading
edited tags
Link
Loading
Source Link
Loading