Quantcast
Channel: Adobe Community : Discussion List - LiveCycle Forms
Viewing all articles
Browse latest Browse all 1160

How to make table cells mandatory when visible

$
0
0

I have a form with two hidden subforms. Each subform contains a table with fields that need to be mandatory when visible.

The subforms are hidden or revealed based on a selection from a drop-down list.

I found the below script which works great for making a text field mandatory when visible, but, how do you apply this to cells in a table?

I can't figure it out.

 

if ("RMC-Fort Lupton-FIRE-DOT" == xfa.event.newText)

{

    Table.FL.presence = "visible";

    Table.FL.TextField1.mandatory ="error";

}

else

{

    Table.FL.presence = "hidden";

    Table.FL.TextField1.mandatory ="disabled";

}

 

if ("RMC-Ault-FIRE-DOT" == xfa.event.newText)

{

    Table.ALT.presence = "visible";

    Table.ALT.TextField2.mandatory ="error";

}

else

{

    Table.ALT.presence = "hidden";

    Table.ALT.TextField2.mandatory ="disabled";

}

 

Thanks in advance!


Viewing all articles
Browse latest Browse all 1160

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>