AUTO POPULATING TEXT IN FEILDS RELATIVE TO A DROPDOWN SELECTION

New Here ,
Mar 17, 2022 Mar 17, 2022

Copy link to clipboard

Copied

Hello. I am trying to create a dropdown with about ten selections, then with that selection, make data relative to that
specific selection auto populate in separate fields.
For example, If I create a dropdown and I select "home" from my dropdown, I want my street address to populate in
the next field, the city in the field after, and so on with the state and zip code. If I were to select "work", I would want
my work address to auto populate in the next several fields.
For clarification, I know how to create the dropdown with the selections, I just can not figure out how to get the
relative information for each selection in the dropdown to auto populate.
If I select "HOME" from the dropdown, what do I need to do to get "123 Anywhere St" to populate in the
ADDRESS field, "New York" in the CITY, "New York" in the STATE, and 55555 in the ZIP fields?

TOPICS
Windows

Views

67

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Adobe Community Professional , Mar 17, 2022 Mar 17, 2022
First make sure 'Commit selected value iimmediately' is selected in dropdown field -> options tab and make sure you use "HOME" or "home" because it's case sensitive. Use like this as 'Validation' script of dropdown field, just add more of 'else if' for other choices: if(event.value == "HOME"){ this.getField("ADDRESS").value = "123 Anywhere St"; this.getField("CITY").value = "New York"; this.getField("STATE").value = "New York"; this.getField("ZIP").value = "55555";} else if(event.value == "WORK"...

Likes

Translate

Translate
Adobe Community Professional ,
Mar 17, 2022 Mar 17, 2022

Copy link to clipboard

Copied

First make sure 'Commit selected value iimmediately' is selected in dropdown field -> options tab and make sure you use "HOME" or "home" because it's case sensitive.

Use like this as 'Validation' script of dropdown field, just add more of 'else if' for other choices:

if(event.value == "HOME"){
this.getField("ADDRESS").value = "123 Anywhere St";
this.getField("CITY").value = "New York";
this.getField("STATE").value = "New York";
this.getField("ZIP").value = "55555";}
else if(event.value == "WORK"){
this.getField("ADDRESS").value = "999 Anywhere St";
this.getField("CITY").value = "Los Angeles";
this.getField("STATE").value = "California";
this.getField("ZIP").value = "77777";}

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Mar 18, 2022 Mar 18, 2022

Copy link to clipboard

Copied

LATEST

THANK YOU! THIS HAS BEEN AWESOME!

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines