Copy link to clipboard
Copied
I have a long drop down list of countries in one field and i want to generate an automatic abbreviation for those counties in another field
for example if I choose France from the drop down field, i want the other field to automatically show FRA,
and if i choose Kuwait from the drop down, i want the other field to show KWT and so on...
Copy link to clipboard
Copied
In the dropdown list use the abbreviations as export values. Then you can use the selected value in the other field.
Copy link to clipboard
Copied
can you please further explain what you said, i am veryyy new to adobe
Copy link to clipboard
Copied
In the properties of the dropdown list you can assign the export values to entries of the list.
Copy link to clipboard
Copied
does anyone know a simple script that can generate that??
Copy link to clipboard
Copied
Once you apply the export values as Bernd described you can use a simple script to copy the selected value to the text field.
If the drop-down is called Countries you can use this as the custom calculation code of the text field:
event.value = this.getField("Countries").valueAsString;
The values themselves can also be applied using a script, like this:
this.getField("Countries").setItems([["Kuwait", "KWT"], ["United States", "USA"]]);
If you already have the names and codes in a text file or spreadsheet then you can use this (paid-for) tool I've developed to easily import everything at once, without having to write any code yourself: Custom-made Adobe Scripts: Acrobat -- Import Items from a Text File to a Combo-Box or List Field
Get ready! An upgraded Adobe Community experience is coming in January.
Learn more