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

troubleshooting scripts

goodbye
Registered: Jul 7 2008
Posts: 49

I am using Livecycle ES to create a client run JavaScript form. And it is going very well. It is a lot of showing and hiding of sections and I use very simple code to do this.

On docReady I do this on the subform:

this.presence = "hidden";

And on change for the radio buttons, or checkboxes, I do this:

if (this.rawValue == "1") {
mySubformName.presence = "visible";
}
else {
mySubformName.presence = "hidden";
}

In the subforms there may be just a text box with information or additional subforms with more to show and hide. I have this part working just the way it needs to be for the user.

But here is where I get into trouble, on the fourth page of this document it seems that all of a sudden this type of code fails for the third set of subforms on that page.

When I add the third set, then the second and third set will not work. I take out the third set then the second one starts to work again. I have checked my instance names and they are all unique. These two are using a single checkbox each instead of a set of three radio buttons.

I have similar script on the fifth page and it works fine. So it seems to only be on this page.

Apart from instance names, maybe I am missing someother way to check this? I am new to it so . . .

I am at a lost as to why this is happening. Any suggestions for troubleshooting would be greatly appreciated. Thanks. :)

EDIT: if I change those elements to invisible rather than hidden it does work, but I would still like to know why hidden won't work? Has it to do with if a subform is flowed or positioned?

My Product Information:
LiveCycle Designer, Windows
lkassuba
ExpertTeam
Registered: Jun 28 2007
Posts: 3636
Have you tried using the Javascript Debugger in Acrobat to help troubleshoot? Here is a link to further information [url=http://livedocs.adobe.com/livecycle/8.2/acrobat_designer/wwhelp/wwhimpl/common/html/wwhelp.htm?context=Adobe_LiveCycle_Designer_Help&file=001094.php]To Enble the JavaScript Debugger for LiveCycle Designer.[/url]

Lori Kassuba is an AUC Expert and Community Manager for AcrobatUsers.com.