google-apps-script

GAS all Triggers disabled suddenly. why?

别来无恙 提交于 2020-04-16 06:12:35
问题 all my GAS triggers (time based) in all my projects are disabled: checking the trigger page shows a red "Disabled" under "last run" and text inside says: Disable reason You do not have access to the target script. can someone explain what is going on? 回答1: The error you obtained is caused by the following constellation User A created a file User A shared his file with user B User B either created a bound script and attached an time-driven trigger to the script, or User B attached a time

GAS all Triggers disabled suddenly. why?

六眼飞鱼酱① 提交于 2020-04-16 06:11:43
问题 all my GAS triggers (time based) in all my projects are disabled: checking the trigger page shows a red "Disabled" under "last run" and text inside says: Disable reason You do not have access to the target script. can someone explain what is going on? 回答1: The error you obtained is caused by the following constellation User A created a file User A shared his file with user B User B either created a bound script and attached an time-driven trigger to the script, or User B attached a time

GAS all Triggers disabled suddenly. why?

本小妞迷上赌 提交于 2020-04-16 06:11:42
问题 all my GAS triggers (time based) in all my projects are disabled: checking the trigger page shows a red "Disabled" under "last run" and text inside says: Disable reason You do not have access to the target script. can someone explain what is going on? 回答1: The error you obtained is caused by the following constellation User A created a file User A shared his file with user B User B either created a bound script and attached an time-driven trigger to the script, or User B attached a time

How to shuffle every second column with google apps script?

自闭症网瘾萝莉.ら 提交于 2020-04-16 06:09:11
问题 I want to randomize D:E, F:G, H:I, J:K if C is 4 with google apps script. At the moment I use this inefficient & time-consuming code: function shuffleAnswers() { var arr = [0, 2, 4, 6]; for (var i = 2; i < lastRow()+1; i++) { var amount = sheet().getRange(i,3).getValue(); if (amount == 4) { var source = sheet().getRange(i,4,1,2); var column = 4 + arr[(Math.random() * arr.length) | 0]; var destination = sheet().getRange(i,column,1,2); var valuesSource = source.getValues(); var

google.script.run stopped working in my web application

时间秒杀一切 提交于 2020-04-16 05:49:08
问题 my google web app has been running since months without issues. Today I suddenly get the error "Uncaught (in promise) TypeError: Cannot read property 'run' of undefined". Nothing was changed in the code 回答1: The answer has been found in the meanwhile. Apparently, on some PC's it was working, on others it wasn't. After clearing the browsing history (and cookies) on the PC, all was working again. 来源: https://stackoverflow.com/questions/60944335/google-script-run-stopped-working-in-my-web

google.script.run stopped working in my web application

半腔热情 提交于 2020-04-16 05:48:49
问题 my google web app has been running since months without issues. Today I suddenly get the error "Uncaught (in promise) TypeError: Cannot read property 'run' of undefined". Nothing was changed in the code 回答1: The answer has been found in the meanwhile. Apparently, on some PC's it was working, on others it wasn't. After clearing the browsing history (and cookies) on the PC, all was working again. 来源: https://stackoverflow.com/questions/60944335/google-script-run-stopped-working-in-my-web

Google Script: Match RegEx into 2D array

倖福魔咒の 提交于 2020-04-16 05:47:49
问题 I'm trying to extract information from Gmail into Google Spreadsheet. The information in the email has a table structure with the following columns List of Products, QTY Sold and the Subtotal for each product. These repeat N times. When accesing the information using message.getPlainBody() I get the following text: Product Quantity Price Chocolate 1 $8.58 Apples 2 $40.40 Bananas 1 $95.99 Candy 1 $4.99 Subtotal: $149.96 Progress First I tried to use a regular expression to identify each row

Google App Script HTML table styling

狂风中的少年 提交于 2020-04-16 04:06:07
问题 I've created a function within GAS that takes data from google sheets and sends out individual emails based on a specific person; the function then loops to the next person and continues through the data. What I am having issue with now is formatting the HTML table that I've created by looping through the data. When I run this the data shows up in a table format but I am unable to add borders, color, ect. I currently have the styling under the TABLEFORMAT variable but I've also tried putting

Call showSidebar() from a cell in google spreadsheets

假装没事ソ 提交于 2020-04-16 03:43:09
问题 As user Serge insas answered here, Ui Dialogs can not be called by time triggered functions, they have to be triggered by a user action, that's to say a click on a menu item or some sort of button that calls the function showing the UI. What about calling showSidebar() or showModalDialog() from a cell? Something like the following formula, which should open the sidebar automatically when the value in A1 is greater than 0: =if(A1>0;showSidebar();"nothing to show") Is this possible? This is my

Reset checkboxes to false - implemented solution not working

南楼画角 提交于 2020-04-16 03:38:07
问题 I have a column of checkboxes which the user can set to true or false - I want to run a Google Apps Script on the click of a button which resets the value of all the checkboxes to False. I found a related question, and attempted to implement the solution from the accepted answer. Unfortunately, it doesn't seem to work as intended, and I don't know enough about Apps Script to understand why. Here is my code (barely modified from Tanaike's solution): function resetBoard() { var sheet =