Questions tagged [google-apps-script]

For questions about using Google Apps Script to extend Google applications

Filter by
Sorted by
Tagged with
0
votes
1answer
242 views

Multiple timestamps in multiple columns on multiple Google Sheet tabs

I am trying to work out what script is required to have multiple timestamps on several tabs however each one I have tried doesn't work for me. I am new to this. When text is added to column 2 I need ...
-1
votes
1answer
83 views

Google Sheets Appscript on apply filter event?

I want to execute a script as soon as I apply a filter to my Sheet. I can't find any event in the App script Docs that will allow me to do this, no onFilter event or anything obvious anyway. Does ...
1
vote
1answer
58 views

Insert timestamp in row when formula result changes in the same row in Google Sheets

I am trying to add a timestamp when a particular cell returns TRUE. With help from this community, I was able to modify the code below. It works perfectly if I type in TRUE. However, when a formula's ...
0
votes
2answers
22 views

Add one Column to Another, Then Delete the Column

This is a messy function but it works. I want to input values into column D, use the macro, have it add D values to C Values across from one another, then Delete all D values. I could write out C3:...
1
vote
1answer
53 views

How to stack two columns in Google Sheet with column name in another column?

I have these columns in the Google Sheet. Date A Date B 1/1/2020 3 5/2/2021 328.28 1/2/2020 41 5/3/2021 322.75 1/9/2020 23 5/25/2021 342 1/12/2020 54 5/28/2021 ...
0
votes
1answer
17 views

Add all tabs to a script with out having to manually add them to the script

I am trying to make this as simple as possible for users in our office that may not know how to edit script.. right now I have the following code (see below) however I have to list out each sheet name ...
0
votes
1answer
65 views

Add a new row and move data to that row when box is checked

I currently have a Google spreadsheet that keeps track of all orders and the progress: Column 1: Order Form Sent Column 2: Order Form Received Column 3: Delivered to Pick Up Site Column 4: Picked Up ...
0
votes
1answer
35 views

How can I transform a form created in Google Sheets into an App or something that can be used by multiple people that also autoupdates?

So, I've created a form of sorts in Google Sheets. No, I don't mean a Google Form linked to a spreadsheet, I mean a literal form created directly in a Spreadsheet. Picture for reference: I've already ...
0
votes
1answer
87 views

Why does this Google Apps script for Gmail not do anything?

I am using the following script from Any way to send Gmail auto-response at certain times every week?. It does not send the expected email. function autoReply() { var interval = 5; // if the ...
0
votes
1answer
295 views

I need to automatically change data validation rules after adding row for all rows underneath

I am completely new to scripts. I have created a complex template on Google Sheets for accounting. I am using dependent drop-down lists. As it is a template and plan is to add rows for the items in ...
0
votes
1answer
628 views

Google Apps Script - While loop

I would appreciate any inputs on this Google Apps Script code! I am trying to implement a do-while loop to copy the formula from cell B2 to C2 and follow that sequence from B3 to c3, B4 to c4, and so ...
0
votes
1answer
633 views

Script to search my Google Sheets for a partial text match in a cell and if it contains a match then clear or delete entire cell

I thought this would be more simple and easy to find online, but I'm having a difficult time so I'll try here first. I'm Looking for a script to search my Google Sheets for a partial text match in a ...
0
votes
2answers
600 views

Trigger for onChange on add new row only

I want the trigger which work for 'add new row' only, but not other edit function. Right now the changeType of the onChange are Edit(include add new row), INSERT_ROW (but not add new row), etc., which ...
0
votes
1answer
113 views

How can I identify a Google Sheets drawing in Google Apps Script?

I use Google Sheets to produce simple quizzes for students. Instead of just having a cell display <Good!> when a kid enters a correct answer, I'd like to make a drawing pop up. A sports fan ...
0
votes
1answer
118 views

How can you use a Gmail script to attach more than one image at a time?

I'm trying to set up a Google Sheet with some data to email images. I have the code I found online working below to send a single image attachment but I would like to send more than one image at a ...
0
votes
1answer
10 views

cells auto-populating from code when sheet is not called

I have built a code to reset cells to a certain value when a button is pushed. It works perfectly in the sheet that I want it too, however, it is auto-resetting in two other sheets as well, even ...
0
votes
1answer
56 views

Create events from a spreadsheet and write relevant ids back to the spreadsheet

I have a function to create events for field based workers. Eventually I will add this to an onEdit trigger and give the user (centrally based admin worker) some functionality to edit/delete events ...
0
votes
1answer
28 views

How do I code 3 series dependent drop down on multiple sheets?

I have a code to run a 3 tier dependent drop down list - it currently works for one sheet in my workbook named "BlankNode" but I need it to work for ~20 different sheets. I tried adding a ...
0
votes
1answer
27 views

Sync dropdown cells and edit it

Sorry English is not my native language but I can't find anything to this topic and I hope you understand my writing/problem and can help me. I have a huge google sheet with many columns. But for this ...
0
votes
1answer
436 views

Trying to run two functions onEdit

I have found two scripts that work independently, but fail when combined. I get this error message ReferenceError: myfunction2 is not defined onEdit @ Code.gs:3. I want one field to populate the ...
0
votes
1answer
76 views

Adding Multiple timestamps, One with Checkbox

I am looking to add a second timestamp, connected to a checkbox. I currently have it set to put a timestamp in Column D when B is filled in. I would also like a timestamp in Column O when Column A ...
-1
votes
1answer
22 views

Sort rows from highest to lower value problem

So I'm using a script that is sorting my rows from the lowest number to the highest but I want it to do upside down, gonna try to explain it better, the script now sort the rows like this And I want ...
0
votes
1answer
108 views

When uploading a file on Google Forms, I would like the file uploads to go into a custom folder based on the form response (their name)

Ex. someone submitting the form with a file upload and on form submit it creates a custom folder based on their form response (their name) on Google Drive with their submission in it. Using this ...
0
votes
1answer
102 views

Google Sheets sorting and lookup

I have a table like this : Now I would like to perform a column lookup on this where I give the Client(B) and get return value from Status(C) but the latest date from Date (A). I tried using vlookup ...
0
votes
2answers
67 views

Generate sequential numbers in first column based on value in other column

I'm having a problem implementing a spreadsheet with several sheets that use data registered continuously on the first. I found a solution with this script on the forum but I don't know how to edit, I'...
-1
votes
2answers
260 views

ReferenceError: MONTH is not defined

Using the following Google Sheets script: var currentMonth = MONTH(TODAY); I receive the error ReferenceError: MONTH is not defined. Why is MONTH not defined?
-1
votes
1answer
58 views

how to select and automate "copy by value" to persist data in Google Sheet

I would like to use Google Sheets as a form to query for data, select and store the data I'm interested in. Below what I'd like to try. Please let me know if feasible, and if so, could you tell how to?...
0
votes
1answer
128 views

Range returning null using getRange

I am new to Google Apps Script and the docs are a little fuzzy on the returned data from a method call. I want to loop through a range, but it is coming back as null. What am I doing wrong? var ...
0
votes
1answer
64 views

Problems with form and appendRow

I created a form in Google Script and one of the fields is a Checkbox, the name of the field would be field1 [] and to save the answers in a sheet, I am using AppendRow, but when I insert the name of ...
0
votes
1answer
240 views

Google Apps Script MailApp Not Sending Email To Script Owner

I've set up a script to take information from a Google Form and email that information to multiple people using Google Apps Script. What it does not do, however, is email the owner of the script. I'...
0
votes
1answer
26 views

Google Sheets Google Forms updates

I have created a Google Form for which collects data from a user. Once the use submits the form I have scripts that copy the data to several other Google sheets and then send an email to the ...
-1
votes
1answer
16 views

Send email when cell value equals 29 [duplicate]

I am having trouble with my google sheets script and I wondered if anyone had any advice for a beginner. I want my script to check a cell value (Sheet1, H2), then send an email if the value = 29. ...
0
votes
1answer
43 views

Sending an email with just an attachment with script

Here is my script for forwarding emails to another inbox. However, now I want to only send emails that are unread with attachments to one email and then if no attachment to a different email. Can ...
0
votes
1answer
26 views

Depending on Sheet being edited, get a cell value and trigger OnEdit update

This code works but not as intended. The workbook has several tabs (Sheets) and if the user is editing Tab1, then and only then a trigger OnEdit should execute. If the user is editing some other tab (...
-1
votes
1answer
47 views

Autofill Google Form for Sent Emails

Problem: I need to keep a comms log for emails sent by my teams to other teams. We are running a multiyear project that has over 150 customers. We often escalate and get responses from directors ...
0
votes
1answer
24 views

How to sort by merged cells in Google Sheet

I have been using this script for sorting and so I know it works. Now I'm trying to use it on a new Google Sheet project. Except that the column I want to sort the entire sheet by isn't just one ...
0
votes
1answer
20 views

Protect identical ranges across multiple Sheets

I currently have a multitude of docs each containing 30-60+ sheets. Each sheet is formatted identically with the same headers/column labels. In doing research I found its not possible to mass protect ...
0
votes
1answer
282 views

Add image in Google Doc from Google Sheet via Script

There is an image in Google Sheet (coming from Google Form) that I would like to insert in Google Doc in Image Format. Currently, I'm getting Url only from the below mention script. How can I get the ...
0
votes
1answer
16 views

Run Google Sheet Script Running for 1st entry only

I am currently running a google script to create a PDF from Google Form Inputs. I have moved my Form Response Sheet data to the 3rd row(image attached) (using the 2nd row for another formula). Every ...
0
votes
1answer
125 views

Is there a way to prevent spreadsheet from updating the date to today's date in formula? [duplicate]

I'm trying to print the date when I change the value on a cell (status column). But spreadsheets update the date to today's date. I wish it could save the date from when the status was changed. The ...
0
votes
1answer
95 views

Run a Google Sheets script on all tabs except one

Thanks in advance for the help. I am currently running a Google Sheets script which applies to one tab called "Tab 1". It copies a range across to the next free column as follows: function ...
0
votes
1answer
42 views

Google Sheet Search Button

Sorry beginner and just starting to try Apps Script just for a few weeks. I'm create a form for my Inventory Tracker with few button 'Search', 'Clear Form', 'Save Data', 'Update Data' and 'Delete Data'...
0
votes
1answer
1k views

Embed an interactive calculator in my website using Google Sheets

I have implemented a calculator in a Google Sheet, and would like to embed it in my website. There will be multiple users. They should be able to enter numbers and see the result, perhaps with a chart,...
2
votes
1answer
688 views

Logging a value that changes once a day in Google Sheets [duplicate]

In my Google Sheet cell D12 gets the difference of two numbers with =D9 - D4. How do I store the value in cell D12 to a log in another sheet on a daily basis? I would like each row in the log sheet to ...
0
votes
1answer
70 views

ReferenceError: OFFSET is not defined [duplicate]

When running the function: function updateCells() { var ss = SpreadsheetApp.getActiveSpreadsheet(); var spreadsheetSummary = ss.getSheetByName('Summary'); const range = spreadsheetSummary....
0
votes
1answer
22 views

Only the first thread is displayed in my Apps Scripts program, but I need all the threads

My issue is that the first thread in my inbox is being displayed 45 times which is the number of messages in my inbox. What I need is the for loop to go through all the threads and gather all the ...
0
votes
0answers
46 views

Copy Google Sheet's cell if there is today's date in any cell next to [duplicate]

I need a formula that would copy all the cells from column B if there is today's date in any cell next to (same row). The copied cells would go to empty column I, each cell under the next.
0
votes
1answer
20 views

Google Spreadsheet Alert Scripts

Wanting to add an alert so if the information entered here if not all filled in as required it send you an alert. function Repair1() { var ss = SpreadsheetApp.getActiveSpreadsheet(); var r ...
0
votes
1answer
3k views

Exception: The parameters (number) don't match the method signature for SpreadsheetApp.Range.setValues

With the following function: function updateCells() { var ss = SpreadsheetApp.getActiveSpreadsheet(); var spreadsheetSummary = ss.getSheetByName('Summary'); const range = spreadsheetSummary....
1
vote
1answer
99 views

ReferenceError: CONCATENATE is not defined [duplicate]

I am receiving an error when manually running this function: function updateCells() { var ss = SpreadsheetApp.getActiveSpreadsheet(); var spreadsheetSummary = ss.getSheetByName('Summary'); const ...

1 2 3
4
5
33