How to disable all fields in a Dynamics 365 CRM Form?
Background:
Disabling all fields of the Dynamics 365 form may be necessary for certain scenarios, such as when performing data migration or making bulk updates to records.
This prevents users from inadvertently making changes to the data during the process, ensuring that the migrated or updated data is accurate and complete.
Additionally, disabling fields can temporarily prevent users from entering or modifying data until certain conditions are met or specific actions are taken.
Test scenario:
For example, if a user has submitted a request for approval and it’s currently in the “Pending Approval” status, then they are not allowed to modify any data in the Form.
Test Environment:
Product: Dynamics 365 CRM online
Entity: Account
Event: on load
Logic: If [Status Reason] is [Pending Approval] then disable all fields
Step 1: Write JavaScript
Step 2: Bind On Load Event
Then test it.
Sub-Grid can't be disabled
However, the sub-grid isn't disabled.
About how to disable a sub-grid, please refer to the link below.
How to disable a sub-grid in Form
Not Recommended Solution
Another solution is that we can also achieve the same functionality through Business Rule.
But we have to manually select all fields and when Add/Remove fields from the Form, we have to modify the Business Rule accordingly.
The scalability is not good, so this is not a good approach.
The End
*This post is locked for comments