Question 130
At Timberline Foods, the supply-chain systems team is implementing a vendor onboarding project under requirements for continuous approved supplier status. After the proposed change, the release reviewer requires evidence for: A model-driven form script uses a global form object and edits the wrong record when the same library runs on another form. Which result BEST proves the intended fix is effective?
Explanation
Correct Answer
The handler reads and updates the field on the currently open form in both forms without cross-record state leaks. This directly tests whether the reported failure has been corrected: A model-driven form script uses a global form object and edits the wrong record when the same library runs on another form. The intended action was Accept the execution context and obtain formContext from the event instead of assuming one global form instance. The observed Timberline Foods outcome is stronger evidence than a completed ticket or a saved configuration alone.
Incorrect Answers
The form retrieves permitted records under the signed-in user's privileges and source code contains no token. Such evidence would validate a different change: A JavaScript form extension tries to call Dataverse REST endpoints with a hard-coded bearer token in browser source. It follows the separate remedy Use supported Xrm.WebApi client operations that follow authenticated user context rather than embed OAuth credentials. The Timberline Foods scenario instead reports A model-driven form script uses a global form object and edits the wrong record when the same library runs on another form. The decisive observation must be: The handler reads and updates the field on the currently open form in both forms without cross-record state leaks.
The script locates the intended field on each form and reports a controlled error if the attribute is unavailable. Such evidence would validate a different change: An OnChange handler fails with an undefined field error after a form designer renames a control but not its Dataverse column. It follows the separate remedy Use supported formContext attribute APIs and verify logical column names independently of UI control labels. The Timberline Foods scenario instead reports A model-driven form script uses a global form object and edits the wrong record when the same library runs on another form. The decisive observation must be: The handler reads and updates the field on the currently open form in both forms without cross-record state leaks.
Users receive one actionable notice for the rule violation and the notice disappears when the field becomes valid. Such evidence would validate a different change: A form displays a modal alert on every keystroke, interrupting data entry while a rule is being evaluated. It follows the separate remedy Use contextual form notifications and controlled dialogs only at meaningful events, clearing stale messages after correction. The Timberline Foods scenario instead reports A model-driven form script uses a global form object and edits the wrong record when the same library runs on another form. The decisive observation must be: The handler reads and updates the field on the currently open form in both forms without cross-record state leaks.