Copy link to clipboard
Copied
I'm creating a form that will use pull down menus with basic choices to start. I will have the box checked to let the user enter custom text. Is there a way to have that custom entry automatically add itself to the existing pull down menu items so that it is available as an additional choice to the user the next time they fill that field out?
Copy link to clipboard
Copied
I'm creating a form that will use pull down menus with basic choices to start. I will have the box checked to let the user enter custom text. Is there a way to have that custom entry automatically add itself to the existing pull down menu items so that it is available as an additional choice to the user the next time they fill that field out?
Copy link to clipboard
Copied
I believe this can only be done through Scripting.
I'm moving this post to the Scripting forum to see if someone else is able to answer this question for you.
Copy link to clipboard
Copied
Make sure to tick the "Allow user to enter custom text" box, as mentioned by Cari, as well as the "Commit select value immediately" box, (shown in the same screenshot), and then apply the following code as the field's custom validation script:
if (event.value) {
var found = false;
for (var i=0; i<event.target.numItems; i++) {
if (event.value==event.target.getItemAt(i)) {
found = true;
break;
}
}
if (!found) event.target.insertItemAt({nIdx: event.target.numItems, cName: event.value});
}