I'm new to Google Apps Script and I'm having the following issue :
I have created a Google Form which I will send to some end user for them to complete. However, in one of these fields, there's a huge dropdown list of every city in my state (to simplify). I don't want to maintain either to fill this dropdown nor maintain it, this is why I'm looking for a way to populate this very dropdown with datas from a column in another spreadsheet I created.
And this is where I'm stuck. I don't even manage to log an "Hello world" because I can't seem to understand how any of this works.
I have opened the script editor from within the Google Forms editor and added this very basic code :
function onOpen(e){
var form = FormApp.getActiveForm();
var items = form.getItems();
for (var i in items) {
Logger.log(items[i].getTitle() + ': ' + items[i].getId());
}
}
What I understand is that my app script is automatically connected to my google forms and so this code should run everytime any end user opens up the form.
That would be amazing if you could tell me what I'm doing wrong or even tell me what I didn't understand...
Thanks a lot !