Save Your Contacts to Address Book¶
Scenario¶
Use this example when a process should maintain a simple address book by saving form rows into a relational database and loading them back into the form later.
Prerequisites¶
- permission to create processes and relational schemas
- access to prework and postwork scripting
- a process form that can host repeating contact rows
Steps¶
Create the Folder, Process, and Task¶
- Create an application folder, for example
Address Book. - Create a process and open it in edit mode.
- Rename the opening task to
Definition. - Add
UpdateandCancelactions.

Build the Form¶
- Open the form designer.
- Add a tabbed content control, for example
Contacts. - Add a table-content control inside that tab.
- Create the columns required for the contact rows, such as name and phone number.
- Set the phone field type to Telephone.

Extend the Data Model¶
Add an Id field under the repeating contact structure so each contact row can be uniquely identified.

Define the Relational Database¶
- Open the database area of the process.
- Create a schema such as
AddressBook. - Add a table such as
Contacts. - Define the required fields, including a unique identifier column for the contact ID.

Save the Form Data in Postwork¶
In the task postwork, write the submitted rows to the relational database with ImportFromXml:
1 2 3 4 5 6 7 8 9 10 11 12 | |
This persists the rows from the XML form data into the Contacts table.

Load the Existing Contacts in Prework¶
In the task prework, load the saved rows back into the form with ExportToXml:
1 2 3 4 5 6 7 8 | |
This makes previously saved contacts appear when the form is opened again.

Test the Address Book¶
- Commit the process changes.
- Start the form.
- Add a contact row.
- Select
Updateto save it. - Open the form again and confirm the saved contact is loaded back into the table.

Result¶
The process now behaves like a lightweight address book: it saves repeating form rows into a relational table and loads them back when the form is reopened.