Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [google-apps-script]

For questions about using Google Apps Script to extend Google applications

1
vote
2answers
105 views

I have a google sheet full of important links to images on google drive. Is there a way to get MD5 Checksum from the files with a custom formula?

Here is my scenario: No. | PHOTO | MD5 CHECKSUM FROM PHOTO FROM G-DRIVE | 01 - LINK TO PHOTO 1 - MD5 CHECKSUM 1 02 - LINK TO PHOTO 2 - MD5 CHECKSUM 2 03 - LINK TO PHOTO 3 - ...
0
votes
1answer
94 views

Google Script - createFolder() issue

I am running into a weird problem where the createFolder function just freezes. I get no error no failure and its just stuck there. I have it running on another sheet with no issue but in this ...
0
votes
1answer
204 views

Google Sheets - Fetch random value from array for each new line created with form

I have a Google Form that fills up a new line with values in Sheet1!, column A and column B. I am trying to create an =ARRAYFORMULA function in column C, which will populate the C cell in each new ...
1
vote
1answer
63 views

Dynamic generation of sheet name from cell content (cell contents from importrange)

I have a list of names of the members of my group. Each member has a separate sheet that contains information on that member. When a new person joins the group, I input the name to the master list and ...
0
votes
0answers
37 views

Cursor to go to a particular cell

I have created some buttons so that user may click on them and go to a particular report on the same Tab in my Google Sheet file. A sample of my Google script code is as under; function ...
1
vote
2answers
66 views

Querying if cells exist in an external Google Drive file

I have a huge list of names stored in Google Drive as a TXT file (constantly updated externally). Can I put a small list of names in a Google Sheet and see if any of them exist in the big external ...
0
votes
1answer
98 views

how to apply script on specific sheets within a spreadsheet?

script (attempt): function moveValuesOnly() { var ss = SpreadsheetApp.getActiveSpreadsheet(); var source = ss.getRange('P1!B10'); source.copyTo(...
0
votes
0answers
45 views

Saving Google Doc as PDF isn't showing all images

I'm trying to set up a Google Sheet that populates fields and inserts images in a Google Doc template and downloads it as a PDF. I'm having some trouble with the images part - in particular, when I ...
0
votes
0answers
10 views

Looping through a set of results to update the master data

I have a Google sheet that records payments received out in the field, and I have another tab that collates the information using SUMIFS, INDEX(MATCH) etc, to give us a summarized list of receipts per ...
0
votes
1answer
534 views

Clear the contents of the active sheet

I'm trying to clear the contents of certain cells in the active sheet of my google sheets spreadsheet. Here's what I have so far: function Reset() { var sheet = sheetName(); var range = sheet....
0
votes
0answers
57 views

Copy and paste with vlookup script

I'm trying to create a script which daily copies the range A1:E30 in Sheet1, looks for the value in A2 in column A in Sheet2 and pastes it starting there. Sheet1 is daily updated with data for the ...
0
votes
1answer
234 views

Google Forms - App script won't iterate through all form fields

I have made a Google Form and onSubmit an app script will run iterating through all form questions and answers however some questions, when the corresponding answer is left empty, are not listed/...
0
votes
1answer
36 views

Automatic insertion of current date when rows are entered via Zapier

Unfortunately, as a new user I am not allowed to comment. This is why I need to do a new post regarding to this topic: Insert current date to cell based on content in other cell This is my code in ...
0
votes
1answer
37 views

Increment the numeric value of Col D by 1 if Col E is “True”

I have tried to follow the example below to color E to Red if E = True Figured I would keep changing the script until What I want is to increment the value in Col D by 1 if the Value of Col E is "...
0
votes
0answers
25 views

Protect the Formatting on a public Google Sheets Spreadsheet [duplicate]

I have a shared spreadsheet that users can edit data in. The only problem is, that whenever someone copy and pastes data, the format changes, and I'm always going in to fix it (somewhat of a pain). I ...
0
votes
0answers
197 views

Google Sheets: Multiple tab data querying, filtering, and compiling

I have dozens of tabs on a google sheets worksheet that all utilize the same template, each cell utilizes data validation drop down menus--a plant information database of sorts. I would like to ...
0
votes
1answer
375 views

Auto insert Formula on the next empty row upon form submit

I have a spreadsheet that contains 3 columns with leave request data coming from a google form. [From Date] [To Date] [Name of the Requestor] 5/16/2018 5/18/2018 John 5/18/2018 5/20/...
0
votes
1answer
848 views

Google App Script TypeError Cannot Call Method getSheets of null

Wondering if anyone can assist in debugging this Google app script. The script works as needed to create CSV files of each Sheet in my workbook, but it throws an error every time: "TypeError: ...
0
votes
0answers
49 views

Looking to clear a cell range when a certain dropdown value is selected in Google Sheets with Script

I am using a Google sheet to track brewery tank inventory. We have columns for tank number, status, brand, etc. The lab will flag test with pass and release when the products are clear to package. ...
-1
votes
1answer
76 views

Google scripts get address not working

I'm trying to create an app that imports contacts and puts them in a spreadsheet, but I keep getting this error: TypeError: Cannot call method "getAddress" of undefined This even happends from the ...
0
votes
1answer
45 views

Google Apps Script to automatically send email

I am trying to create a Google Apps Script that will send an email to our client's general inbox when we receive an email from one of their representatives containing an order. We are required by our ...
0
votes
1answer
160 views

Move rows on 2 sheets older than 24 hours to archive

I have been trying to figure this one out for a while now and would really appreciate some assistance. I have a Google Sheet that is being updated by a Google Form. Due to this I needed to mirror the ...
0
votes
1answer
89 views

Is it possible to trigger a google script externally?

Backstory: We use Google Sheets via Gsuite and have several users. I'm using the admin account and creating some parsing scripts that load a CSV, extract processed data and place them into the google ...
0
votes
1answer
1k views

Find & Replace part of the text

I would like to ask if it's possible to find & replace part of text in specified range and still preserve rest of the text as if you do it with Ctrl+H. I am using this script function replace(){...
2
votes
1answer
49 views

Make function only work on first sheet, not in whole Google Sheets file

I have the following code which is for tracking the date of any edit made in a particular row. However, this code applies to the whole spreadsheet file, I would like to change this to be for the 1st ...
0
votes
1answer
499 views

Edit custom file properties in Google Drive UI

Once I was looking through Google Drive API docs and I have seen a picture of Google Drive UI and a sidebar on the right, I guess it allowed to edit custom file properties. I need to let the user add ...
0
votes
0answers
140 views

How can I continue a series within a formula

I have a custom function I'm using in Google Sheets that follows the following command order: VAR('API-reference','API-variable','date','refresh-cell'). I am wanting to autofill the date so that I can ...
0
votes
1answer
28 views

Copying file with cell data only

I have been trying to copy file with cell data only but unsuccessfully. I have a Google sheet documnet with importxm function of about 2000 rows. When the function runs it populates the cells but ...
0
votes
1answer
590 views

Pasting timestamp for edits by multiple users in Google Sheets

I got a good Google Sheet script for pasting a time stamp at the designated column of the same row on editing any cells of another particular column. Here it is On Edit of column 11: timestamp is to ...
0
votes
1answer
2k views

How to set up delays in Google Apps Script?

I'm using the following method to encode URLs in Google Sheets: How do I convert a cell to RFC 3986 standard (URLEncoded) in Google Spreadsheets? It works. The only problem is – when I apply it to a ...
1
vote
1answer
39 views

Automatic organization of confirmations/rejections in Gmail

I need to manage better my email into Gmail. I can receive two possible email messages: one for confirmation and the latter for rejection. A rejection email will come after a previous confirmation. ...
0
votes
1answer
196 views

Move Google Sheet with a script to Excel

I have a Google Sheet that I would like to access and modify also when I'm offline. The problem is that I have a script attached to it so I can't use the "make available offline" option; the script ...
1
vote
1answer
648 views

How to duplicate a Google Sheet template sheet dynamically, preserving the protected cells permissions

I have two Google Sheet script functions that both work independently: 1) duplicates a template sheet, populating each duplicate sheet from a separate row of data in a source range; 2) makes a single ...
0
votes
0answers
185 views

Need to multiple (50-100 copies) duplicate sheets with protection

I have been able to build scripts that duplicate the protection in a single duplicate process, and I've also been able to build a simple script that will create 100 tabs using tabnames identified in ...
0
votes
1answer
67 views

Moving Google Sheets Project to Client's G-Drive

BACKGROUND: I have a project folder in Google Drive that contains - 2 Spreadsheets - 1 Folder There are several scripts attached to the Spreadsheets. One of these scripts create n number of copies ...
1
vote
0answers
27 views

Get the current Value of a random function [duplicate]

I have a sheet that contains a random function and a script that is trying to store the current value of that function. However, whenever I use the script and copy the values, the values change, even ...
1
vote
1answer
904 views

How to use my Google scripts on all my sheets?

I created a Google Sheets script (actually copied and pasted it). It works on the sheet I was when I created the script, but not on others. Is there a way to "activate" the script to another sheet? ...
0
votes
1answer
424 views

Delete Duplicate Rows Based on 1 Column

I am looking for a Google Sheets script that will delete anything after the first instance of a duplicate row but only search column B. I found the following script on here but it only addresses ...
0
votes
1answer
105 views

Inverse of Google Sheets GetSpreadsheetNameById

This post Display sheet name in Google Spreadsheets shows how to get the name of a Google sheet, given its URL. I have the opposite problem. I know the Spreadsheet name, but I want the URL to use in ...
0
votes
1answer
2k views

How to manipulate text strings in Google Apps Scripts

I've found this super userful code that I have managed to add to a Google Sheet (total newbie here) but I have a couple of problems. The first is to disregard blanks. I want to select a list, get ...
0
votes
0answers
33 views

Google Sheets Click a cell to open hidden cells

I am using Google sheets to create a contents page of folders, so one folder per cell. Within each folder is a list of files and some have subfolders, each taking up a cell. What I want is for these ...
5
votes
1answer
302 views

Calculate remaining duration based on percentage

Ultimately, all I'm trying to do is calculate completed hours based on percentages from an original duration. I have the following in Google Sheets (manually entered for display): The only columns I ...
1
vote
1answer
103 views

Google Sheets setRowHeight() Permissions?

I am trying to add a function in a Google Sheet. I am the sheet owner. I have made sure there are no sheet protections. The function runs for a second, then: /#ERROR! "You do not have ...
2
votes
1answer
270 views

Change function from running only on Active Sheet to run on All Sheets (tabs)

I have a script (from here) that changes tab name based on cell value. This works great on the active sheet but I would like it to check and change all tabs based on cell B2 of each tab. function ...
2
votes
1answer
590 views

Put the timestamp of last edit on master sheet, next to edited sheet's name

I'm trying to come up with a script that will print a timestamp of the last edit made to a specific tab within a google sheet. Imagine you have 17 retail stores, each one having its own tab with a set ...
0
votes
0answers
607 views

Creating new sheets based on values in a particular column

I am very new to Google Apps Script but here's what I would like to do. I have data coming into a Google Sheet from a Google Form. I would like to create a script that takes each unique value from ...
1
vote
1answer
280 views

How to fill out an Apps Script OAuth Client Verification form - Link to Privacy Policy

In order to avoid a warning that your Apps Script code is "Unsafe" and not verified, you need to fill out an Apps Script OAuth Client Verification form. Link to Application Form: OAuth Developer ...
0
votes
0answers
104 views

Fixing daily Google app scripts about unsuccessful execution

A while ago I used the Google Drive Expiration script on my Google account for sharing files. In a recent check through my privacy and security details for my account, I was reminded of this and, ...
2
votes
1answer
1k views

Mail Google sheet as excel attachment by Google Apps Script

I have a Google Spreadsheet with some different sheets. I want to send my Google Spreadsheet as excel attachment to some specific addresses in everyday morning. How can I do this easily? I have heard ...
1
vote
2answers
281 views

Convert all links to images in a Google Document with actual images

I've got a few Google Docs that contain some paragraphs of text and multiple Drive links in the following format: https://drive.google.com/open?id=XXXX How can I use a script to replace all the ...