mercredi 18 septembre 2019

Livecycle javascript - Creating a list of checkboxes and radio buttons to hide/show sections

This is my first question ever on stackoverflow. Please be gentle.:)

I am working in Adobe Livecycle and I am hoping to create a condition where a section will hide or show based on the user's selection on a set of radio buttons and eight checkboxes. I am wondering how I could create a script that would check the list of checkboxes as well as the radio buttons to make sure they are checked, or not checked to determine whether or not to show or hide the other sections?

This is what i have so far, but somehowthe && is not doing anything. It will show and hide tomostSubform.test1 by selecting the radio button, but not together with the checkbox.

if ( topmostSubform.Page1.Section3.PlantLocation.PL1.rawValue ==1 && topmostSubform.Page1.Section3.RadioButtonList.rawValue == 1 ) {
 topmostSubform.test1.presence ="visible";
}

else {
 topmostSubform.test1.presence ="hidden";
}

I am not a programmer so it will be much appreciated if anyone could provide any examples with explanations. Thank you very much!

Aucun commentaire:

Enregistrer un commentaire