Questions tagged [google-apps-script]

Use for questions about Google Apps Script, Google's server side Javascript-based cloud scripting platform for automating tasks across Google products and third-party services. Use in addition to relevant product-specific (e.g. [google-sheets], [google-docs]) or API-specific (e.g. [google-drive-api]) tags where applicable

Google Apps Script Logo

Google Apps Script is a server side Javascript-based cloud scripting platform for automating tasks across Google products and third-party services.

Here you'll find links to wonderful resources, helpful tips on asking better questions, and secret chat room links.


How to ask?

General information:
  • Well researched questions are better received by the community. You can start researching by reading or searching the issue in the official developer documentation and the FAQ. Don't ask questions because you want to know the answer, ask questions because you want others to know the answer!

  • Avoid asking questions that are goal oriented. Split up your goal into smaller questions and ask them one by one. For eg, avoid asking "How to create a Google sheet with sports information from this API?". Instead, start writing your code and if you run into a problem getting the correct information, ask "How to send the correct authentication request to this sports API using my username and password, as sending it directly gives me 404?". The latter is a programming question. The former is a business project. Asking volunteers to do unpaid work is frowned upon. See Why is "Can someone help me" not a actual question?

  • Always provide minimal reproducible example. The code should be as minimal as possible, preferably within ten to fifteen lines of code. This requires you to debug your code and takes effort on your part. You can start the process by "Starting from scratch". Don't start with where you are and start reducing. Start from scratch and start adding one by one. See minimal reproducible example.

  • If you reach this point and you are still struggling on how to fix / improve your first question, please read What is the proper way to approach Stack Overflow as someone totally new to programming?. You might also post a question on Meta Stack Overflow including a link to your post. If you get an error when trying to post to Meta, please checkout I'm asking a question about my own post, but I'm still prompted that I need 5 reputation to post here. What gives?.

Specific information:

Tag usage guidance

This is a summary of tags related to Google Apps Script and how to use them in the question being asked.


Community Chat Room

Note: Stack Overflow chat requires a minimum reputation of 20 or be "invited" by a Stack Overflow moderator.


Official Resources


Community Resources


Best Practices


FAQ:

:

53079 questions
5
votes
2 answers

Google Spreadsheet: Array formula if/and to return "No" if 3 previous cells are blank

I can't post a link due to sensitive information, but I can provide the structure: |Id |PT/DOT |Primary Employee |From |To |Per x Days |Frequency Data Complete? | ------ --------- ----------------- ------- ----- ------------…
thoughtcrime
  • 293
  • 3
  • 9
5
votes
1 answer

Customize confirmation page after submitting google form

I have this google form (just using google drive), this is like a test with multiple choices, so the thing is when a user completes the form and clicks on submit button, I want the confirmation page shows the test results. Is it possible? I try…
Ricardo
  • 7,921
  • 14
  • 64
  • 111
5
votes
1 answer

Script to generate random numbers in multiple cells

Looking for a way to generate random numbers from 1-9 in cells c2:f2; duplicate values are OK as long as its a number in each cell and the values change only when I click a button or something in that regard, not every time I type something in a…
user3079271
  • 65
  • 1
  • 1
  • 4
5
votes
2 answers

Is there a way to keep two sheets synchronized?

There isn't a way to share only one sheet of one spreadsheet in Google Docs. So, you have to share an entire spreadsheet. So, I was thinking in writing a script to synchronize two sheets (each one in a different spreadsheet). I thought using a…
craftApprentice
  • 2,697
  • 17
  • 58
  • 86
5
votes
3 answers

Emailing a chart from a Google spreadsheet with apps script

I've search high and low for an answer but without an y luck. Got a Google spreadsheet which uses apps script to connect to a database to pull in some raw data into a spreadsheet. I then use various spreadsheet formulas to manipulate that data and…
The Ginger Fox
  • 367
  • 1
  • 4
  • 15
5
votes
1 answer

How do I fix charset problems in .gs script?

I have a problem with charsets. I parsed a csv file in google-app-engine and I'm posting to an uiapp table. But I checked special characters like áéíóú and those are not well displayed (?square symbol). When I was setting up my code I played writing…
Antonio E.
  • 359
  • 1
  • 9
  • 27
5
votes
1 answer

vbscript to auto detect open window and close it OR Google Apps Script to control form submit button

In the past I've used the script below to detect if an active window with the title "Remote Desktop" is or isn't active. If it isn't active the script will auto launch or make it active again. Question: Is there a way to detect if a window is…
user2116516
  • 139
  • 1
  • 2
  • 11
5
votes
2 answers

BigQuery with Google Spreadsheet error 'Required parameter is missing'

UPDATE: This is the fix: var request = BigQuery.newQueryRequest(); request.query = sql // Inserts a Query Job try { queryResults = BigQuery.Jobs.query(request,projectNumber); } catch (err) { Logger.log(err); …
5
votes
1 answer

Is it possible to have a google form confirmation message that displays part of the response data?

I am setting up a google form for an upcoming auction. As bidders arrive at the auction, we will have them fill out a basic google form (i.e. name, address, ID) and a a 'Bidder ID' is auto generated based on the row number in the response…
user2951063
  • 121
  • 1
  • 2
  • 4
5
votes
2 answers

How to write to existing file on google drive via google apps engine?

I am trying to create a google spreadsheet with an extra menu. This menu would trigger an action which would create a customized string of the content. This string needs to be written to an existing textfile stored already on google drive. While…
5
votes
2 answers

How to make a call from one Google Apps Script to a function in another?

Is there an easy way of making a call from one Google Apps script to a function in another? I'm writing two scripts, one which should use functions from the other. I want the two to have different sharing permissions, however, so I don't want to…
wils484
  • 275
  • 1
  • 3
  • 14
5
votes
2 answers

Get child index of findtext in google API script

My goal is to replace a piece of text in a Google Drive document with the contents of another document. I have been able to insert the document at a certain position in the other document, but I'm having trouble determining the child index of the…
user2846736
  • 71
  • 1
  • 4
5
votes
1 answer

Google Apps Script - How To Publish / Install A Container-Bound Script

I have a document container-bound script, that I would like to publish, I would like to make it available to people in my google apps organization. I know the script gallery is only available to spreadsheet apps, so how do I publish it. Or, more…
Ari Porad
  • 2,834
  • 3
  • 33
  • 51
5
votes
1 answer

Unable to activate a sheet by name

I'm trying to activate a monthly sheet upon opening the Spreadsheet, according to the current month. The problem is at the end of the script, when it fails selecting the sheet. It seems that getSheetByName() gets a null value, which is not accepted…
Enrique Umaran
  • 115
  • 1
  • 1
  • 9
5
votes
3 answers

Google Scripts in Sheets: Script Experienced an Error (How to get the error!?)

My question is mighty simple: how do you get the error message!? All I have to go off of is the red box at the top that says "Script CustomSort Experienced an Error," which is almost as vague as one can get! Going deeper, the following worked about…
Zoop
  • 965
  • 1
  • 13
  • 24
1 2 3
99
100