Prefilling a child form refers to the act of automatically filling in some of the fields in a child form when creating a new record in the linked records field. It's important to note that this feature only applies when you are creating a new record and not when editing an existing one. There are two ways to set this up. If both are used simultaneously for the same field, the child form will use the static prefill.
Using Static Prefill
This method is applicable when you want the same prefill value to be applied to all new records. This is commonly used if you want to prefill a field that is not included in the Form fields, e.g. Status = Pending. To configure this, you can follow these steps:
Using Dynamic Prefill
Dynamic prefills are used to automatically populate child form fields with information from a field in the main table (the form's table, or the users table when using a portal). This is commonly used in cases where you have different types of users and each type is prefilled in a different way. To set this up, you need to go to:
Portal Tables or Form Fields
Click on the linked records field or the table in question (if using a portal)
Creating and Editing Records section
Turn on Allow users to create new records toggle.
Turn on Prefill child form for creating records toggle.
In Airtable, create a formula field in your main table (the form's table, or the users table when using a portal). The formula should be something like:
'?prefill_fieldNameFromLinkedTable=' & {fieldNameFromMainTable}
.
The first field is the field name of the field you want to prefill in the linked record, and the second is the field that holds the value in the main table.Once you have created the formula field, select that field as the prefill field on miniExtensions. You may need to refresh the fields list and wait a moment for it to appear.
This dynamic prefill method only works if the record in the main table already exists. If you're creating new records with your main form, but want to still use this dynamic prefill for linked record, you'll need to use Save & Continue mode and ensure that a save takes place before creating the linked record (e.g. by putting the linked record field on any form page that isn't the first).