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

Dropdown Selection

libraboy
Registered: Dec 14 2007
Posts: 94

Hi,

I am using LC to build a form for a non organization just to help out. Just wondering if I can create a drop-down box with showing some fields?

Ex. If I select 1 from the drop down 1 field should show up & if I select 4from the drop down 4 fields will show up.

Please advice ASAP.

Thanks & more power to this FORUM.

lIbRaBoy

My Product Information:
LiveCycle Designer, Windows
radzmar
Expert
Registered: Nov 3 2008
Posts: 1202
In case, that all textfields exist in the form but their presence set to "hidden", you can use JavaScript in the change event of the drop down field to control the visibility.

if (xfa.event.newText == "1"){TextField1.presence = "visible";TextField2.presence = "hidden";TextField3.presence = "hidden";TextField4.presence = "hidden";}if (xfa.event.newText == "2"){TextField1.presence = "visible";TextField2.presence = "visible";TextField3.presence = "hidden";TextField4.presence = "hidden";}if (xfa.event.newText == "3"){TextField1.presence = "visible";TextField2.presence = "visible";TextField3.presence = "visible";TextField4.presence = "hidden";}if (xfa.event.newText == "4"){TextField1.presence = "visible";TextField2.presence = "visible";TextField3.presence = "visible";TextField4.presence = "visible";}

radzmar
LoveCycle Blog
Documents you need:
LiveCycle Designer ES2 Docs

libraboy
Registered: Dec 14 2007
Posts: 94
I need a command for LC to show a subform to show. Please also tell me where to insert the command.

Thanks for your help!