Add repeatable sections to a form
Adaptive Forms Block provides the capability to add or make a section or a component of a form repeatable. This allows users to enter information multiple times for the same type of data, making it easier to collect information like work experience or educational background.
For example, consider a form used to collect information about a person’s work experience. You may have a repeatable section for capturing details of each previous job. The repeatable section would typically contain fields such as company name, job title, dates of employment, and job responsibilities. The user can add multiple instances of the repeatable section to enter information about each job they have held.
By the end of this article, you learn to:
Create a repeatable section
Creating a repeatable section in a form offers users the ability to input multiple instances of the same set of data, allowing for the efficient collection of repetitive information. To create a repeatable section in a form:
-
Go to your Edge Deliver project folder on Microsoft SharePoint or Google Workspace and open your spreadsheet.
-
Add a form field with the
typeproperty set tofieldset -
Specify
Nameof the field. The name property is used to create a repeatable section. -
Enable repeatability by setting
repeatabletotrue. -
Specify a descriptive
labelfor the field. It serves as the heading for the repeatable section.Refer to the image below for an illustration of an employment history section within a job application form.
-
For each field you want to include in the section, set its
Fieldsetproperty to the same name you chose in step 3.For instance, designate
experiencein the Fieldset property of all relevant fields to be included in theemployment historysection.
-
Use AEM Sidekick to preview and publish the sheet. The repeatable section is added to form.
Underneath the repeatable section, users find an intuitive Add button, facilitating the addition of multiple sections with ease.
Setting Minimum and Maximum Repetitions
In form design, it’s beneficial to set minimum and maximum repetitions for repeatable sections. By doing so, you establish control and consistency while guiding users effectively. To set minimum or maximum number of repetitions:
-
Go to your Edge Deliver project folder on Microsoft SharePoint or Google Workspace and open your spreadsheet.
-
For a field of
typefieldsetandrepeatableproperty set totrue:-
set the
minproperty to specify the minimum number of times the section can be repeated. -
set the
maxproperty to specify the maximum number of times the section can be repeated.
-
-
Use AEM Sidekick to preview and publish the sheet.
On adding a repeatable section, users find an intuitive Delete icon, making it easier to remove repeatable sections. Once added, these sections cannot be decreased to fewer instances than specified by the
minproperty. This ensures adherence to the minimum requirement set for the form’s completion.