Objective
After reading this article, you will understand how to prepopulate related lists onto forms.
Before you get started
These articles might be helpful before you read further:
Introduction to Shared Linked Sections
Use the Shared Linked Section to prepopulate a form with a related list from a record in Salesforce. For example, if a form maps data to an account, and you want to list all of the contacts for that account, then the form template could use a Shared Linked Section to display the contacts for that account.
To create a Shared Linked Section, visit an existing Linked Section in the Template Builder. Edit the section, and visit the Shared Linked Sections tab.
The numbers below correspond to the numbers in the image above:
- Form Lookup For Sharing is where you choose the parent record for your Shared Linked Section. For example if you have field links to the Form Account, and you wish to use that as your parent record, you should choose disco__Form_Account__c which is the api name of the Form Account field on the Form object.
- Linked Section Lookup for Sharing is where you select which lookup field on on the child record (contacts in this example) that the Shared Linked Section should use to identify its relationship with the parent lookup (account in this example). In this example, if the Form is being filled out for the Account XYZ, the Shared Linked Section will populate the lookups on all of the Contact records with Account XYZ.
- With Linked Section Order By Field and Shared Linked Section Sort Order you can designate the order in which the Shared Linked Section records will display. In this example, the Shared Linked Section will prepopulate Contacts from the parent Account, by Last Name from A-Z.
- Linked Section Sharing Section Limit allows you to set the maximum number of records that the Form will prepopulate.
- Linked Section Sharing Filter lets you specify which of the related records (contacts, in this example) will prepopulate on the Form. Here we're choosing to only populate the form with Contacts that are less than 50 years old. Linked Section Sharing Filters allowing you to choose None (meaning all records in the related list will populate in the form), Simple (as shown in the image above), or Advanced (which allows you to write a WHERE clause using condition syntax).
Considerations for Shared Linked Sections
- Shared Linked Sections do not populate when creating a new Form in an offline state. They work if a Form is created online, and then taken offline, but the list of items will show up empty if the Form record is created when the device has no connectivity.
- Considering using the Linked Section Compact View to make the information in the Shared Linked Sections more digestible
- In order for a "complete forms" user to be able to Edit or Add linked section records, they must have Create permissions on the related Salesforce object.
Comments
0 comments
Please sign in to leave a comment.