Expand my Community achievements bar.

Guidelines for the Responsible Use of Generative AI in the Experience Cloud Community.
SOLVED

FormCalc problem...

Avatar

Level 4

I have 4 subforms wrapped in another subform that is set to "flowed". For practicality, I will call the contained subforms A, B, C and D. Within "A" are several checkboxes, "B", "C" and "D" are on top of each other and are set to "hidden". For the corresponding checkbox I have the following code in the "layout:ready" section:

if ($ eq 1) then

  B.presence = "visible"

else

          B.presence = "hidden"

endif

if ($ eq 1) then

  C.presence = "visible"

else

  C.presence = "hidden"

endif

if ($ eq 1) then

  D.presence = "visible"

else

  D.presence = "hidden"

endif

The problem is if I check "B", "C" and "D", they show properly, but when I uncheck on, say "B", the others stay in the same position instead of moving up. How do I make it so when a subform is again hidden, the others move up to fill the space from the now hidden subform?

1 Accepted Solution

Avatar

Correct answer by
Level 10

Hi,

this maybe a problem of the target version of your form.

Add the line xfa.layout.relayout() to the and of each of the scripts.

View solution in original post

1 Reply

Avatar

Correct answer by
Level 10

Hi,

this maybe a problem of the target version of your form.

Add the line xfa.layout.relayout() to the and of each of the scripts.