4
votes

I need a help. I am using Google App Scripts for creating Google Forms. How I can change form's color/palette?

I tried to find here https://developers.google.com/apps-script/reference/forms/, but nothing found.

3
I don't see anything in the documentation to change the forms color. - Alan Wells
Any update on this? - Oneezy

3 Answers

4
votes

For the moment you can't, FormApp works with the first version of Forms, so for the moment no templates available programmatically.

Last news on the subject here

2
votes

I was facing the same issue here and found a workaround: create a "Template Form" with the proper theme you want, then you make a copy of it and do your coding to the new copied form.

The problem is, if you want to custom each form with a theme, it would need several template forms, and the code should be able to select the correct template. However, this is not my case. Here is a sample code:

var file = DriveApp.getFileById('your-template-form-id').makeCopy();
var form = FormApp.openById(file.getId());

Just make sure you remove the single question that is created within the template form if you're adding questions dinamically, else, add the questions you need.

0
votes

Good to note that once you generate a form programmatically, you can then edit it just like a regular form. You get the link to the editable page from form.getEditUrl().