Adobe LiveCycle Designer: Hide/Show Multiple Subforms via Drop Down List

Xeverus picture Xeverus · Aug 3, 2012 · Viewed 9.1k times · Source

Good afternoon,

Quick question here. Could someone show me the code needed to hide / show subforms in Adobe LiveCycle Desier ES 8.2? I have 3+ subforms that I need to be able to switch between based on a specific country. I'd really appreciate the help. Thank you.

Also, I've been able to get it to work between two selections but now everytime I try to build a form I can't even select an item from the drop down list.

Xeverus

Answer

swapy picture swapy · Sep 21, 2012

you can achieve this by java-script.

on change - (JavaScript, client) event of drop-down you add script.

subform1.presence = "hidden";
subform2.presence = "hidden";

var order= xfa.resolveNode("form1.#subform[0].typeOfIncidentDdl").rawValue;
if (order == 1) {
          subform1.presence = "visible";  
}
if(order ==2){
          subform2.presence = "visible";
}