How to create a cascade delete master-details form?
Last Update: April 22, 2018
Here are the steps on how to create a master-details form using SPARK Forms and how to enforce the relationship when deleting an item from the master form so all related items will be deleted automatically from the detailed list. We are assuming that you already have the following lists created at the root level:
- Countries with the following columns:
- Country Name: Single line of text.
- States with the following columns:
- State Name: Single line of text.
- Master ID: Lookup. Check the "Check Enforce relationship behavior" and select "Cascade delete". This is the Master ID column to be mapped with an ID system column in the parent list "Countries".
- Open the form in
- Add the following to the form design workspace:
- Set the
Required property of txtCountryName and txtStateName controls to ON.
- Select Repeater1.
Control Properties, set the following:
- Data Source: Mapped.
- Mapped To: List.
- Select the Dynamic Data Source icon to configure the repeater
- Configure Repeater1 as follows:
- Publish the form by clicking on the Publish button in Publishing Group in the Form Ribbon.
- Test the form by clicking on an existing item or new item in the Countries list.