I am brand new to JavaScript, but not to Acrobat forms.
Here's the deal. I have a form with 3 yes/no questions. I am using radio buttons (radio1, radio2, radio3). My users may select the yes/no answers in any order (not my call - customer's call). I need to trigger an event -- make a hidden text box visible -- only of the answer is 'yes' to all three questions.
I started out evaluating all three buttons every time a 'yes' answer is selected on each radio button. This would fail on the first two 'yes' answers and succed on the third 'yes' regardless of the order of the entries.
I cannot make it work with JavaScript so far. Here is what I tried:
If
(this.btneAuth1.value=="eAuth1Yes" && this.btneAuth2.value=="eAuth2Yes" && this.btneAuth3.value=="eAuth3Yes")
{eAuthBanner.hidden = false}
else
{eAuthBanner.hidden = true}
Acrobat accepts it without syntax errors, but it just doesn't work.
Help!!!
-Thanks
- You're not hiding the fields correctly.
Have a look here: http://www.adobe.com/devnet/acrobat/javascript.php
Look especially at the Field object and the Document object's method getField.
- AcrobatUsers Community Expert - Contact me personally at try6767 [at] gmail [dot] com
Check out my custom-made scripts website: http://try67.blogspot.com