Copy link to clipboard
Copied
I have a dropdown selection box with several choices.
If I select a specific item, then 3 text boxes below show. Otherwise if any other selection is made, they stay hidden.
This is a script I had before and it is here somewhere, but I can not find it. 😞
Thank you
Copy link to clipboard
Copied
Let's say your choices to show text fields are "choice1-3" and fields are named "Text1-3", as Validation script of dropdown field use like this (change choices and field names to your actual choices and field names):
if(event.value == "choice1" || event.value == "choice2" || event.value == "choice3"){
this.getField("Text1").display = display.visible;
this.getField("Text2").display = display.visible;
this.getField("Text3").display = display.visible;}
else{
this.getField("Text1").display = display.hidden;
this.getField("Text2").display = display.hidden;
this.getField("Text3").display = display.hidden;}
Copy link to clipboard
Copied
It's probably under the field's Validation event (custom script option), or under Format - Custom - Keystroke.
Copy link to clipboard
Copied
Sorry, I meant I cant find it here within acrobatusers. I need the JS, then it goes under Validation I think.
Copy link to clipboard
Copied
Let's say your choices to show text fields are "choice1-3" and fields are named "Text1-3", as Validation script of dropdown field use like this (change choices and field names to your actual choices and field names):
if(event.value == "choice1" || event.value == "choice2" || event.value == "choice3"){
this.getField("Text1").display = display.visible;
this.getField("Text2").display = display.visible;
this.getField("Text3").display = display.visible;}
else{
this.getField("Text1").display = display.hidden;
this.getField("Text2").display = display.hidden;
this.getField("Text3").display = display.hidden;}
Copy link to clipboard
Copied
Hi There. I need to add to this. Each text box has a radio button. It is a button group1 with 3 choices. Choice 1, 2 and 3.
So in the script I tried adding the radio but it did not work.
I would like the 3 radio buttons to show or hide with the text box. Can you help?
Thank you.
Murray
Copy link to clipboard
Copied
Just add this to 'else' part (Inside curly brackets):
this.getField("group1").display = display.hidden;