4

I'm getting the

"We're Sorry, a server error occurred. Please wait a bit and try again."

when trying to save the script

If I run the script as is, it runs an older version

Here's my code:

function myFunction() {
  
  var ss2 = SpreadsheetApp.getActiveSpreadsheet();
  var sheet2 = ss2.getSheets()[0];

  var cell = sheet2.getRange("D3:D6");
  cell.setValue("Out");
  var cell = sheet2.getRange("D8:D12");
  cell.setValue("Out");
  var cell = sheet2.getRange("D14:D17");
  cell.setValue("Out");
  var cell = sheet2.getRange("D19:D31");
  cell.setValue("Out");
  var cell = sheet2.getRange("D33:D42");
  cell.setValue("Out");
  var cell = sheet2.getRange("D44:D50");
  cell.setValue("Out");
}
TheMaster
  • 45,448
  • 6
  • 62
  • 85
  • Try removing any protections in your sheet. – Code Guy Sep 26 '20 at 16:04
  • the "older code" runs fine, so I don't think anything is wrong with the sheet. – richpeterson Sep 26 '20 at 16:29
  • Quick solution: Disable V8. If you need further help please add a brief descripiton of your search/research efforts as is suggested in [ask]. Also include enough details to reproduce the problem as well about the expected results.. – Rubén Sep 26 '20 at 16:31
  • 1
    Tried to disable and I get the same "We're sorry ..." error. I've been getting this error for a few weeks now – richpeterson Sep 26 '20 at 17:08
  • I got it figured out. I deleted the whole project and copy/pasted the same code into a new one (added the appropriate triggers) and I'm getting no errors now. – richpeterson Sep 26 '20 at 17:31

1 Answers1

1

I got it figured out. I deleted the whole project and copy/pasted the same code into a new one (added the appropriate triggers) and I'm getting no errors now.