google-apps-script

Google Sheets Scripts suddenly stop working - Error: “Service not found: plus v1”

人走茶凉 提交于 2020-03-26 00:54:11
问题 I built a Google Sheets document that has lots of scripts and triggers built into it. It worked for the last year flawlessly until recently. Now every Function does not work, even for other users. Even simple functions such as this does not work: function clearForm() { var sheet = SpreadsheetApp.getActive().getSheetByName('Manifest'); sheet.getRange('B4:F4').clearContent(); sheet.getRange('B7:C10').clearContent(); sheet.getRange('D14:D28').clearContent(); sheet.getRange('D30').clearContent();

some users get “No item with the given ID could be found, or you do not have permission to access it” error

你离开我真会死。 提交于 2020-03-25 22:38:14
问题 i have an appscript running fine with most of the users. some users, however, get this error when trying to run the script: (they have the same permission as the other users that runs the script fine): "No item with the given ID could be found, or you do not have permission to access it" any ideas? thanks ! 回答1: I have seen plenty of login/authentication problems with my app during past few days. For me, the error was "Exception: You do not have permission to call Session.getActiveUser." .

How to access template variables in the script section of my HTML file in Google Apps Script?

筅森魡賤 提交于 2020-03-25 19:15:11
问题 I need to access templated variables in the script section of my HTML file. Specifically, I need to use content.price . I can access content.price just fine in the templated section of the body of my HTML. This behaves as expected. <div class="container"> Price: $<?= content.price ?></td> <div id="paypal-button-container"></div> </div> But in the script section, trying to access content.price seems to be throwing an exception. This causes the buttons to fail to render. (It fails silently.)

How to access template variables in the script section of my HTML file in Google Apps Script?

喜夏-厌秋 提交于 2020-03-25 19:13:10
问题 I need to access templated variables in the script section of my HTML file. Specifically, I need to use content.price . I can access content.price just fine in the templated section of the body of my HTML. This behaves as expected. <div class="container"> Price: $<?= content.price ?></td> <div id="paypal-button-container"></div> </div> But in the script section, trying to access content.price seems to be throwing an exception. This causes the buttons to fail to render. (It fails silently.)

BigQuery: No OAuth token with Google Drive scope was found

孤街浪徒 提交于 2020-03-25 16:07:39
问题 I'm trying to replace the contents of a Google Sheet with a BigQuery query. I'm in the Google Sheet and using a script based on these: https://greenido.wordpress.com/2013/12/16/big-query-and-google-spreadsheet-intergration/ Accessing BigQuery with Google Spreadsheet All the script does is pull the info from a BigQuery query and write it to a Google Sheet. But if I just run the script, I end up getting an error: BigQuery: No OAuth token with Google Drive scope was found What do I need to do to

Incorporate hyperlink and link in script for Google spreadsheet

做~自己de王妃 提交于 2020-03-25 16:04:45
问题 I am currently trying desperately to include a hyperlink in my script that, after executing the script, the hyperlink as it is here should be placed in cell C16. The same would be for C17-C19 and in G19 again. function AlteFahrerdatenLeeren(){ var sheet=SpreadsheetApp.getActiveSheet(); var destination="C7:C15"; sheet.getRange(destination).setValue(""); var sheet1=SpreadsheetApp.getActiveSheet(); var destination="C20"; sheet1.getRange(destination).setValue(""); var sheet2=SpreadsheetApp

Incorporate hyperlink and link in script for Google spreadsheet

陌路散爱 提交于 2020-03-25 16:04:05
问题 I am currently trying desperately to include a hyperlink in my script that, after executing the script, the hyperlink as it is here should be placed in cell C16. The same would be for C17-C19 and in G19 again. function AlteFahrerdatenLeeren(){ var sheet=SpreadsheetApp.getActiveSheet(); var destination="C7:C15"; sheet.getRange(destination).setValue(""); var sheet1=SpreadsheetApp.getActiveSheet(); var destination="C20"; sheet1.getRange(destination).setValue(""); var sheet2=SpreadsheetApp

Copying Multiple Slides from a Master Slide Desk using Google Apps Script

坚强是说给别人听的谎言 提交于 2020-03-25 06:04:39
问题 I have created a code which replaces placeholders on google slides. The starting point of this project is a google form. Once the google form has been submitted - then the relevant data from google form is entered on the google slides template. See below code. I am looking to create a question on the form where people will be able to select multiple slides to be included (2 Credential slides for example out of 10) function PoD() { SpreadsheetApp.getActiveSpreadsheet().getSheetByName("A-PoD")

Copying Multiple Slides from a Master Slide Desk using Google Apps Script

你说的曾经没有我的故事 提交于 2020-03-25 06:02:38
问题 I have created a code which replaces placeholders on google slides. The starting point of this project is a google form. Once the google form has been submitted - then the relevant data from google form is entered on the google slides template. See below code. I am looking to create a question on the form where people will be able to select multiple slides to be included (2 Credential slides for example out of 10) function PoD() { SpreadsheetApp.getActiveSpreadsheet().getSheetByName("A-PoD")

How to restrict matches to the first 5 lines of an email body using regex in GAS [closed]

隐身守侯 提交于 2020-03-24 09:43:07
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed last month . I'm using the following script which is working correctly to pull 2 fields out of an email body. This is causing the script execution time to increase significantly due to the amount of content in the body. Is there a way to make this search through only the first 5 lines of the email body? First lines of e-mail: