Google Apps Script (GAS) is a JavaScript cloud scripting language that lets you extend Google Apps and build web applications.

learn more… | top users | synonyms (1)

1
vote
1answer
480 views

Google Apps Script: trying to get the id of a file, outputs an error

I have a folder and inside two spreadsheets. I can open the folder but when I try to get the id of the files inside I get this: Im getting this error TypeError: Cannot find function getId in ...
3
votes
2answers
833 views

How do I automatically expand a =QUERY when receiving submissions from a Google Form?

The Query below 'works' on a line by line basis (when manually filled down), but it does not 'autofill' down when new data is added to the 'responses sheet'. The data being added to the 'responses ...
0
votes
1answer
918 views

Script error trying to populate form drop down menu from spreadsheet

We are trying to link a list on a Google Spreadsheet to a drop down menu on a Google Form. The twist is that this Google Spreadsheet list will be continuously updated and needs to automatically ...
1
vote
0answers
227 views

How to build a decision suport app with Google forms or other Google Apps Script resource?

I want to create an app which helps newbie employers to take some decisions. So, using their answers to a form, the app asks new questions based on previous responses, something similar to a decision ...
2
votes
0answers
584 views

Apps Script Webapp accessing Google Spreadsheet gets #VALUE! on every cell

I have a Google Spreadsheet with a couple of sheets that get data from other spreadsheets via ImportRange function and then calculate numeric values based on that data. Then, I assembled a code ...
1
vote
0answers
147 views

setDataValidation in google script not working

Have a problem with setting data validation rules in a google spreadsheet using apps script. Below are two functions, one is an onChange function which will be triggered whenever a user changes the ...
4
votes
2answers
3k views

How do I implement a script that creates a unique ID for a Google form submission?

I need to create a unique ID upon submission of a form which will be used as a project number for tracking. The number needs to be unique but not based on rows or other changeable data because ...
1
vote
1answer
673 views

Why am I getting an “Authorization needed” error in my dummy web app?

I'm trying to write a Google Apps Script web app, which will, eventually, populate a spreadsheet. However, I'm having a hard time getting started. I have an HTML file: <div> <select ...
2
votes
1answer
103 views

Geocode in Google spreadsheets, keep results

I have a form for internships and I am passing over the address of the internship provider to a function which gives me latitude and longitude for it, which is then consumed by a webmap using tabletop ...
2
votes
1answer
891 views

Making all cells in a column links from the values within the cell?

I have a column of cells in a Google Spreadsheet with values such as: 512 2123 2342 3532 What I would like to do is convert all these into a hyperlink and keep the value as the link text: ...
1
vote
2answers
676 views

GDocs: Send Email Notification Based on Timeframe and a Given Email Address From a Cell?

How specifically does the code found in this article need to be modified to allow for a specified email address column to inform who the reminder should go to? I have an example spreadsheet here with ...
6
votes
2answers
3k views

Pass range in Google Apps script custom function without using A1 notation

I'm new to Google Apps script and I would like to create a function for a spreadsheet that sums cell values when the cells meet certain criteria, such as the background color. Moreover, I'd like to ...
1
vote
2answers
682 views

Google forms script to delete responses counter

I have tried and combined a few pieces of script to delete rows, but this does not reset the counter. Help resetting responses using script would be appreciated. My copy sheet function, and delete ...
5
votes
3answers
2k views

Cell reference with colour formatting

Is it possible to reference a cell in Google Spreadsheets so that cell where it gets displayed also displays it using the same text and cell colour formatting? =A1 Will only reference dell's value. ...
1
vote
1answer
169 views

Run a custom script more than 20 times in Google Spreadsheet

I need a way of running a custom script more than 20 times in my spreadsheet. I'm creating a class assessment spreadsheet that will be used as a master across my school, and it needs to retrieve the ...
3
votes
1answer
824 views

Sum a column except current cell

Is it possible to sum all values in a column EXCEPT the value in the current cell? That is, the cell that is to hold the result. With a normal SUM(E:E) command the result is #REF! with a Circular ...
1
vote
1answer
1k views

Dependent validation in Google Spreadsheets

Here's what I'd like to do. The first selection is Subject (as in a school course). There are 5 subjects. Then there are three sub-selections in drop down lists for each subject: Subject Test Type ...
0
votes
2answers
599 views

Show data from one sheet on another if date is today

I have a list of people responsible for data verification that are changing every day. The schedule is on one sheet. And data verification is on another. What I need is to show only responsible ...
1
vote
2answers
1k views

Can I copy row from one Google Spreadsheet to another based on certain criteria

I have a spreadsheet to track student loan outs: Column A is the student name Column B is how many loan outs they have received Column C is the class period Column D is the teacher name ...
2
votes
1answer
626 views

Can I map specific parts of a Google Form to one spreadsheet, and other parts to another spreadsheet?

Can I map specific parts of a Google Form to one spreadsheet, and other parts to another spreadsheet? Some of the responses on one will be public and viewable by anyone, but others will be private.
0
votes
2answers
346 views

How do I link two Google Doc spreadsheets so that entering a numerical value in one cell of Sheet 1 produces an 'x' in the same cell of Sheet 2?

I know about the importRange function to link two sheets, but I wonder if there's a way so that when a cell's contents are imported to the second sheet, the second sheet will autopopulate the ...
2
votes
1answer
187 views

Grading a Google Spreadsheet by answers given in a Google Form

I'm currently working in a school and students answered a 50 question form on ICT Ability. The results of this form have been put into a spreadsheet and I have to order the names in terms of ability. ...
1
vote
1answer
2k views

Auto populate data in Google Spreadsheet from data in separate spreadsheet?

So, I'm in the situation where I have a Google Spreadsheet with people's names, phone numbers, addresses, etc. Is it possible to, from another spreadsheet (not sheet, different workbook), search the ...
1
vote
1answer
1k views

Copy and Paste Cell Contents Once a Week

As per the title, I want to "move" the contents of a cell one column to the right once a week, specifically Sunday at 11pm Must I use a script for that?
2
votes
3answers
1k views

Split, reorder, concat inline in Google Spreadsheets

I want to split a cell, reorder the pieces and recombine. How do I do that inline. For example: | name | reordered name | | Page,Larry | Larry Page | | Brin,Sergey | Sergey Brin | ...
2
votes
1answer
2k views

Panel with Vertical Scroll Bar that allows navigating to different worksheets

I am attempting to build a Script that would open a window with each worksheet I have in my spreadsheet, allowing me to click on the worksheet name to navigate to that sheet. I found the following ...
1
vote
1answer
231 views

How can I speed up my Google Spreadsheet Script?

I am somewhat new to JavaScript and very new to using it in Google Spreadsheets. I have read that fewer calls to Google Spreadsheet API speeds things up, but I feel like I have as few as possible at ...
6
votes
2answers
3k views

Colorize a cell in Google Spreadsheets based on cell data

I'd like to colorize a cell based on it's contents. 0 = red, 100 = green, and linearly interpolated between. function LinInt(x){ var ss = SpreadsheetApp.getActiveSheet(); var cell = ...
1
vote
1answer
931 views

Data Ranges in Custom Google Spreadsheets Function

I'm trying to create a custom Function in Google Spreadsheets that takes a range as input parameter. function Example(cells){ var values = ...
0
votes
1answer
2k views

Auto date added to adjacent cells when data is entered

I am trying to create a spreadsheet to track student loan outs that will automatically put the date in an adjacent cell. The spreadsheet would be set up like this: Column 1 would be "name" Column 2 ...
1
vote
1answer
285 views

Duplicate check while creating Google Contact with Google Apps Script

I have the following code which creates Google Contacts from a Spreadsheet. The problem is whenever I run the code it creates contacts but has no functionality to check if the same Google Contact ...
2
votes
1answer
483 views

Automatically create a new row each day, on top of older rows

I am looking for a way to automatically create a new row on top of older rows each day. Inside of this row should be the current date.
1
vote
0answers
469 views

Google Docs Forms: Create Checklist Item with adjacent Textfield

Using Google Docs Forms, I'd like to create a checklist with a "quantity" and "comments" textfield adjacent to each checklist item. Is it possible to do this without writing a custom script?
4
votes
1answer
336 views

Pull Twitter Posts into Google Spreadsheets

I would like to set-up a Google Spreadsheet that automatically pulls Twitter search results into the cells. For instance, I'd like to search for "pizza" near "baltimore" and then have any pizza ...
1
vote
1answer
480 views

Changing an onEdit function to run onOpen

I have the function below (found online and adapted and it works) that is an on-edit function, but I want it to run/trigger when an import is done OR on open, as the data will not really be edited it ...
2
votes
1answer
875 views

In Google Spreadsheet, finding what formulas reference a given value

I would like to find out which cells have formula dependencies in a large spreadsheet. I am looking for a way to do something like OpenOffice Tools>Detective>Trace dependents and Edit>Find ...
1
vote
0answers
410 views

Google Apps Script: copy document comments?

I'm working on the following script, which is supposed to look at the current document, grab its comments, make a copy, and copy the comments to the new document. However, I seem stuck. I'm not ...
3
votes
2answers
1k views

How to avoid “invoked too many times per second” error

I made a Google Apps Script, but often I get this error: Script invoked too many times per second in this Google user account. This is the script: function papersControl(tipo, col, prev_cell, ...
2
votes
1answer
683 views

How to automatically open a created text document after it being created

I've used this script to create a Google Document (like word document) with Google Spreadsheet. But, when I do so, the new text document created from a template is placed in the default chosen folder. ...
2
votes
3answers
9k views

How to automatically insert a new row and retain functions/formulas from last row?

I have a table with cells that have functions/formulas, like this one: I need a script that creates a new row, copying with it the functions/formulas of the last used row. I find this script which ...
1
vote
1answer
438 views

Create New Google Spreadsheet with timestamp

I'm trying to create a new spreadsheet once we select the specific function from the custom menu item that's selected. I want the new spreadsheet to be "Sheet" & "Timestamp". Can anyone point me ...
3
votes
1answer
138 views

How can I take the HTML/data from a Google Document and restyle it with CSS?

I have a list in a Google Document that I would like to restlye with CSS. Unfortunately Google Docs no longer allows using CSS/HTML styling within the app itself. What would I need to do to get ...
1
vote
0answers
79 views

Auto paste formula on form submission

I have searched and tried various solutions elsewhere but none seems to work for both conditions. I would like to have the formula: =IF($A2="Elementary", VLOOKUP($B2,'ELEM PRINCIPAL'!$B:$AA,7,false), ...
1
vote
1answer
129 views

Inserting rows and adding a cell reference

I'm trying to automate adding new rows if I'm on the last few rows of my sheet. It works, but since I'm also adding a cell reference to it, and checking the amount of free rows left using ...
1
vote
1answer
961 views

Google Spreadsheets - how to add carriage returns to CSV downloads

In reference to this question: Google Spreadsheet downloaded as CSV comes out on 1 line? Is there anyway to have a downloaded Google Spreadsheet incorporate carriage returns and linefeeds such as if ...
1
vote
2answers
233 views

Is there a way to speed up the auto-increment routine in Google Spreadsheets?

The solutions that have been provided for this question does the job, but when more people submit data at the same time, things go wrong. The same number is used in multiple rows. Is there a way to ...
1
vote
2answers
3k views

Using Macros in Google Documents - is it possible?

I want to be able to have some macros, while writing in a Google Document. The idea is to replace the Quick Parts in Word - so I can have the same functionality in a Google Document. Any ideas?
2
votes
1answer
2k views

Google Script for pulling gmail addresses into a spreadsheet

This Google Script goes through and finds the emails in my gmail which are in a label called "LabelToGet" and send me a link to the spreadsheet created with these emails. It works well, but I have ...
0
votes
1answer
213 views

Creating a class roster in Google Spreadsheets from a split result

A lecturer from the European School of Physiotherapy in Amsterdam stumbled on a particular script I prepared, hoping it would resolve a problem he had. After having had a little chit chat, it turned ...
3
votes
1answer
913 views

Why would this Google Spreadsheet onEdit script be so slow (2 secs to change cells, 3 secs to update)

I've put together a script for a spreadsheet based on what I have seen here and other sources that should provide a simple username and timestamp function. I have another spreadsheet that uses a very ...