Announcements
You've accurately described a common limitation with SubGrids in Dynamics 365 forms when you uncheck "Show Related Records" and try to add new records. The native behavior indeed breaks the parent-child relationship mappings when you move away from the "Show Related Records" functionality.
Let's break down the situation and explore solutions:
Understanding the Problem:
Solutions:
Xrm.Navigation.openForm
(Recommended):
Xrm.Navigation.openForm
.your_relationship_name
, your_child_entity_name
, your_lookup_field_name
) with your actual values.openChildRecordForm
).
Recommendation:
Xrm.Navigation.openForm
(Option 1) is the recommended approach. It provides the most reliable and direct way to ensure that the lookup field is populated correctly when adding new records from a SubGrid with custom filters.By using the JavaScript customization, you can effectively address the limitation of parent-child relationship mappings when using custom filters in SubGrids. Remember to test thoroughly and consider the user experience.
André Arnaud de Cal...
293,354
Super User 2025 Season 1
Martin Dráb
232,498
Most Valuable Professional
nmaenpaa
101,158
Moderator