These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

Two Checkboxes with scripts on same page - only one works depending on which is clicked first

nessw
Registered: Jan 6 2011
Posts: 2

Hi
 
I have two checkboxes with scripts on the same page. The problem is that only one checkbox script will work - depending on which checkbox I click first. They should work completely independently of each other.
 
One checkbox has script:
 
if ($.rawValue == 1) then
subform2.presence = "visible"
else
subform2.presence = "hidden"
endif
 
Other checkbox has script:
 
if ($.rawValue == 1) then
subform3.presence = "visible"
else
subform3.presence = "hidden"
endif
 
Thanks!

DaveyB
Registered: Dec 10 2010
Posts: 70
This may sound silly, but I have to ask ... Does each checkbox have a unique name (ie: different from the other)?


LiveCycle Designer 8.0
"Genius is one percent inspiration, ninety-nine percent perspiration." ~~ Thomas Edison
"If at first you don't succeed, get a bigger hammer." ~~ Alan Lewis
"If the conventional doesn't work, try the unconventional" ~~ DaveyB

nessw
Registered: Jan 6 2011
Posts: 2
Hi, thanks for your response.

Yes they are completely separate with different names.

Not sure if this is significant but - Subform2 is on the same page as the checkboxes. Subform3 is on the next page.
DaveyB
Registered: Dec 10 2010
Posts: 70
Short of adjusting the script to point at an absolute reference for subform3, I'm not sure what could be causing this. I tried a test form using your scripts and it works as expected, the only other thing that could be affecting it is if there is something odd going on with your pagination?

LiveCycle Designer 8.0
"Genius is one percent inspiration, ninety-nine percent perspiration." ~~ Thomas Edison
"If at first you don't succeed, get a bigger hammer." ~~ Alan Lewis
"If the conventional doesn't work, try the unconventional" ~~ DaveyB