0

I would like to pass a unique ID for each google form being submitted but I could not find anything so far.

I am thinking of using google web app script and make a simple input html first to enter unique ID and then a submit button where it redirects to the google form after submit button is clicked. The question is, where do I store that unique id? localStorage or Coockie, I tried this methods using coockies but I could not access that coockie from the OnSubmitForm event from script editor (apps script code). Is there any way that I can store a variable into the browser regarding the domain , so I can access it from any tab?

pranvera hoti
  • 107
  • 3
  • 15
  • You would have to write a script in the receiving spreadsheet with a [trigger associated with the form submission](http://stackoverflow.com/questions/17992718/how-to-get-onformsubmit-to-trigger-automatically). OR use the timestamp, but if they are allowed to edit their submission believe the timestamp will change – Karl_S Apr 10 '17 at 13:50
  • If you are using a Web App, you need to use `google.script.run.gs_ScriptFunctionName()` to send the HTML form data to the gs script. [Apps Script documentation](https://developers.google.com/apps-script/guides/html/reference/run) An "On Form Submit" trigger won't even run from a Web App form being submitted. Unless you want to take input information from an HTML form, send that data to the server, then have the server submit a response to the Form? – Alan Wells Apr 11 '17 at 00:44

0 Answers0