Expand my Community achievements bar.

How to add text fields with a button click

Avatar

Level 3

I'm trying to figure out how to create a button that will add additional text fields while pushing everything below those text fields down and onto a new page if needed.

The form will collect basic information about an employee including information about their children such as the child’s name, the school they attend and the schools phone number.  The form will have those three fields displayed but in the event the employee has more than one child the employee can click on the add child button to add an additional sets of those three fields.

Thanks for the help.

Mike

1 Reply

Avatar

Level 2

There are good tutorials, manuals and examples out there, but here is a start ...

Wrap your fields into a subform that is "Flowed" and "Repeat Subform for Each Data Item".
The parent of this subform needs to be "Flowed" and "Allow Page Breaks within Content".
On your button click event you can do somehting like
_subform.addInstance(1);
(where subform is the name of the subform)

Or you could use a table.

Have fun.