google-sheets

Using Google Scripts to Query Multiple Google Sheets to A View

为君一笑 提交于 2021-01-29 10:25:42
问题 I have a Google Spreadsheet that stores employee availability information for my workplace. Every Sheet has the format shown in the example below, with the date fields changing based on the week for which I am collecting availability. Employees submit availability every week by submitting a Google Form that is linked to these Sheets on the backend. My workplace leadership has directed that I limit each Sheet to contain at most one week of data. 09 Jul - 13 Jul Responses Timestamp | Email

How to set correct answer text in google forms from spreadsheet using script

久未见 提交于 2021-01-29 10:23:45
问题 I want to make auto-grading short-answer quiz using google forms. The data is in spreadsheet. column A has questions. column B has correct answers. column C has explanations. The code below makes quiz, but don't set correct answer in each question. "item.createResponse(an);" seems not working. How do I set correct answer? let form = FormApp.openById(formID); form.setIsQuiz(true); // get data from sheet let ss = SpreadsheetApp.getActiveSpreadsheet().getSheetByName('문제'); let range = ss

How to modify current insert timestamp script to remove timestamp when cell is cleared

瘦欲@ 提交于 2021-01-29 10:00:35
问题 I am currently using the following script to add a timestamp to a cell in Column H when cell in Column A is populated. Problem is, when I delete the contents of Column A the timestamp remains in Column H. I currently have conditional formatting to hide the timestamp if the cell is empty but I really need the contents to be deleted. How do I modify my current script to accomplish this? function onEdit(event) { var sheet = SpreadsheetApp.getActiveSheet(); if(sheet.getName() == "CHECK OUT" ||

Google Spreadsheet API setDataValidation with Regex

[亡魂溺海] 提交于 2021-01-29 09:59:51
问题 Im trying to generate an Google Spreadsheet Template with some Validation with their API, using the Node.Js Package from Google. This is my current Request: { "setDataValidation": { "range": { "sheetId": 1656514345, "startRowIndex": 0, "endRowIndex": 0, "startColumnIndex": 1, "endColumnIndex": 1000 }, "rule": { "condition": { "type": "CUSTOM_FORMULA", "values": [ { "userEnteredValue": "=REGEXMATCH(TO_TEXT(A2:A1000); '([1-9]){4}[-]([1-9]){2}[-]([1-9]){2}$')" } ] }, "inputMessage": "TEST

Getting Boolean Values from Checkboxes and Appending them as Numbers in another sheet, like Database

a 夏天 提交于 2021-01-29 09:46:46
问题 Hi Google Apps Script Programmers, Picture making a kind of database for a sandwich shop in Google Sheets, where most sheets are data tables with column 1 being an autonumber field. The first sheet is the main order form named MySubShop. It'll record the order#, cashier, customer, date/time, and have a bunch of checkboxes for the foods. The second sheet is named Lookups and has lookups for bread types and beverage types only because people can only select 1 type of bread and 1 beverage. The

Google App Script to copy rows into dynamically created tabs based on the value of a column

时间秒杀一切 提交于 2021-01-29 09:45:49
问题 First - I'm a teacher and self-teaching myself apps script, so please forgive my sloppy code. The results of my district's frequent standardized tests are often delivered with all the tests combined into one sheet. They would be much easier to manage if each test were in their own sheets. I modified a function that I found on this site to create one new tab for each unique value in the test column (M). That takes care of having tabs to copy the rows into. It uses an array and I honestly don't

Using BigQuery in Google Sheets, how do I give another user permission to press 'refresh'?

社会主义新天地 提交于 2021-01-29 09:32:13
问题 I have BigQuery permissions, and Google Sheets, under a company owned Google account. I have made a spreadsheet for a colleague, the data for which is there via a BigQuery data connection, which creates a sheet in the spreadsheet with the results of that query. There's a button at the bottom left that tells you how many rows were returned, what time it was run, and has a 'REFRESH' button on it. I can press the refresh button and it refreshes the data by running the query again. My colleague

Clear content in S:S when T:T contains “Copied” Google Script

天大地大妈咪最大 提交于 2021-01-29 09:12:03
问题 I am stuck with, at first sight, simple script. I want to clear a content from cell S when T has value "Copied". What I have at the moment is this: function onEdit(e) { if(e.range.columnStart === 20) { e.range.offset(0,-1).clearContent(); } } I am not sure how to include IF. Also, bear in mind that T column has a formula, so I don't edit it manually, and with this script, it doesn't work. It doesn't have to be OnEdit, I can set a trigger to run the script every minute which is even better,

Running script for multiple search terms found on different sheet

我的梦境 提交于 2021-01-29 09:01:13
问题 I'm trying to get a SCORESHEET to populate from a REPORTSHEET , using a REFERENCESHEET to collate search terms and destination cells. The script I'm running is as below. The idea is that the script finds searchDate 's in the REFERENCESHEET and uses them to locate data columns in the REPORTSHEET : function superAuto() { var report = SpreadsheetApp.openById('REPORTSHEET'); var reportData = report.getDataRange().getValues(); var reference = SpreadsheetApp.openById('REFERENCESHEET'); var

Paste the values for each column until the today's date google apps scripts

廉价感情. 提交于 2021-01-29 08:55:24
问题 I've this table, with some information that are link with other tables, almost all the rows have formulas (you can find on the picture). I update the information on the other tabs and with the formulas, the values and information are pasted in the rows, but I update day by day, so I need to copy/paste the values until the today's day inside this tabs instead of select the columns, and paste values. Like is shown on the picture, from day July 2nd (column) I've the formulas, and the days before