# FormLayoutFunction with RepeatingElement and inputs from prior FormObject

**URL:** <https://community.wolfram.com/t/formlayoutfunction-with-repeatingelement-and-inputs-from-prior-formobject/18871>\
**Category:** Questions\
**Tags:** interface-construction, wolfram-cloud\
**Created:** [September 20, 2021, 6:33pm UTC](https://community.wolfram.com/t/formlayoutfunction-with-repeatingelement-and-inputs-from-prior-formobject/18871 "2021-09-20T18:33:43Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![jv3](https://avatars.discourse-cdn.com/v4/letter/j/b2d939/32.png) [@jv3](https://community.wolfram.com/u/jv3)\
**Post date:** [September 20, 2021, 6:33pm UTC](https://community.wolfram.com/t/formlayoutfunction-with-repeatingelement-and-inputs-from-prior-formobject/18871/1 "2021-09-20T18:33:43Z")

</div>

I want to condition the second page of the form on inputs from the first page.  
Somehow RepeatingElement confounds this.

Step 1: A not-so-conditional conditional layout function

```
condlayoutfunc[priorinput_] := 
  Function[Column[{"Static input", Dynamic[#["values"]]}]];
FormFunction[{
   FormObject[{ "input" -> "Number"}],
   FormObject[{ "values" -> RepeatingElement["Number"]}, 
    FormLayoutFunction -> condlayoutfunc[#input]]}, Identity][]

```

Step 2: Make that a conditional layout function

```
condlayoutfunc[priorinput_] := 
  Function[Dynamic[Column[{input, #["values"]}]]];
FormFunction[{
   FormObject[{ "input" -> "Number"}],
   FormObject[{ "values" -> RepeatingElement["Number"]}, 
    FormLayoutFunction -> condlayoutfunc[#input]]}, Identity][]

```

That does not work. But if I omit the RepeatingElement

```
condlayoutfunc[priorinput_] := Function[Dynamic[Column[{input}]]];
FormFunction[{
   FormObject[{ "input" -> "Number"}],
   FormObject[{ "values" -> RepeatingElement["Number"]}, 
    FormLayoutFunction -> condlayoutfunc[#input]]}, Identity][]

```

It works – though doesn’t really do much. What am I missing? How to make the FormLayoutFunction conditional on inputs from prior pages for a page that includes RepeatingElements?
