How to add new line in google form short answer type question
To add new line in google forms short answer type question, add the following code in the script editor :
code to be added :
function addLineBreaks()
{
var form = FormApp.getActiveForm();
// find form items you need
var questions = form.getItems(FormApp.ItemType.TEXT);
for(i = 0; i < questions.length; i++)
{
var title = questions[i].getTitle();
questions[i].setTitle(title.split(". ").join("\n"));
}
}
Comments
Post a Comment