Copy link to clipboard
Copied
Hi all,
I have made a form with dropdowns in Acrobat Pro and it works fine.
But when a customer filled in the form and mail it back, something stange occur:
The vallue of a dropdown field is correct, till it scrolls out the page in Reader.
Then when scrolling up again, the vallue is reset to the standard value of tha specific product.
Do anybody have an idea how it comes and most of all: how to solve this issue?
I searched a lot on the internet, but couldn't find any solution.
Thanks in advance!
Copy link to clipboard
Copied
The dropdown field that resets is a dependent dropdown, ruled by antoher dropdown.
The custom javascript (I got from the internet) from this dropdown is:
var dependentListBoxFieldName = "dependentDropdown2";
var dependentListValues =
{
"FALK 1000-TR": [
["1000-TR 40-75 - RC=2,16", "1000-TR 40-75 - RC=2,16"],
["1000-TR 50-85 - RC=2,61", "1000-TR 50-85 - RC=2,61"],
["1000-TR 60-95 - RC=3,05", "1000-TR 60-95 - RC=3,05"],
["1000-TR 80-115 - RC=3,99", "1000-TR 80-115 - RC=3,99"],
["1000-TR 100-135 - RC=4,92", "1000-TR 100-135 - RC=4,92"],
["1000-TR 125-160 - RC=6,06", "1000-TR 125-160 - RC=6,06"],
["1000-TR 150-185 - RC=7,17", "1000-TR 150-185 - RC=7,17"]
],
"FALK 1100-TR3+": [
["1100-TR 3+ 40-70 - RC=2,07", "1100-TR 3+ 40-70 - RC=2,07"],
["1100-TR 3+ 50-80 - RC=2,52", "1100-TR 3+ 50-80 - RC=2,52"],
["1100-TR 3+ 60-90 - RC=2,99", "1100-TR 3+ 60-90 - RC=2,99"],
["1100-TR 3+ 80-110 - RC=3,91", "1100-TR 3+ 80-110 - RC=3,91"],
["1100-TR 3+ 100-130 - RC=4,82", "1100-TR 3+ 100-130 - RC=4,82"],
["1100-TR 3+ 130-160 - RC=6,17", "1100-TR 3+ 130-160 - RC=6,17"],
["1100-TR 3+ 150-180 - RC=7,07", "1100-TR 3+ 150-180 - RC=7,07"]
],
"FALK 1000-GL": [
["1000-GL 43-83 - RC=2,52", "1000-GL 43-83 - RC=2,52"],
["1000-GL 60-100 - RC=3,31", "1000-GL 60-100 - RC=3,31"],
["1000-GL 80-120 - RC=4,26", "1000-GL 80-120 - RC=4,26"],
["1000-GL 120-160 - RC=6,14", "1000-GL 120-160 - RC=6,14"]
],
"Specials": [
["FALK 1140-KV 80 - RC=3,67", "FALK 1140-KV 80 - RC=3,67"],
["FALK 1140-KV 100 - RC=4,61", "FALK 1140-KV 100 - RC=4,61"],
["FALK 1140-KV 120 - RC=5,55", "FALK 1140-KV 120 - RC=5,55"],
["FALK 1140-KV 140 - RC=6,50", "FALK 1140-KV 140 - RC=6,50"],
["FALK 1060-WB 60 - RC=2,61", "FALK 1060-WB 60 - RC=2,61"],
["FALK 1060-WB 80 - RC=3,55", "FALK 1060-WB 80 - RC=3,55"],
["FALK 1060-WB 100 - RC=4,50", "FALK 1060-WB 100 - RC=4,50"],
["FALK 1060-WB 120 - RC=5,45", "FALK 1060-WB 120 - RC=5,45"],
["FALK 1060-WB 140 - RC=6,40", "FALK 1060-WB 140 - RC=6,40"],
["FALK 1060-WB 160 - RC=7,35", "FALK 1060-WB 160 - RC=7,35"]
]
};
if ((event.target.type == "combobox" && event.name == "Format") || (event.target.type == "listbox" && event.name == "Keystroke")) {
if (event.target.type == "combobox") {
if (dependentListValues.hasOwnProperty(event.target.value)) {
this.getField(dependentListBoxFieldName).setItems(dependentListValues[event.target.value]);
}
else {
this.getField(dependentListBoxFieldName).clearItems();
}
}
if (event.target.type == "listbox" && dependentListValues.hasOwnProperty(event.changeEx)) {
this.getField(dependentListBoxFieldName).setItems(dependentListValues[event.changeEx]);
}
}
else {
app.alert("This script was not intended for this field type or event.");
}
Maybe it has something to do with this code??