I'm trying to get a New Form working for a child Dataverse table. There are many defaults that should be set - some are the current date and current user, others would be set from the parent record.
Rather than implementing the 'If(Parent.FormMode=New, ... , ...)' pattern on every Form control's Default property, does it make sense to create a new record using the 'Defaults()' function, and pass that into the form as a Context Variable? If so, should the Form be set into 'New' mode, or 'Edit' mode (since it's receiving an Item, rather than being asked to create it's own default item)?
Hi @LenC ,
Actually Defaults(DataSource) will pre-populate the form with the default values set in that data source, not in the App.
Check the doc link below:
Defaults function in Power Apps - Power Platform | Microsoft Docs
Best regards,
Good morning, @LenC , I am not sure If I clearly understand your question. But to use the Edit mode of the Form, the record that you are passing for the Form to be referenced by the Item property must be an existing record in the Data source.
WarrenBelz
791
Most Valuable Professional
MS.Ragavendar
410
Super User 2025 Season 2
mmbr1606
275
Super User 2025 Season 2