You create a client script that hides the ‘Date of birth' field on a model-driven app form.
Your script is a JavaScript code that implements a Client API model.
Here is the HideDOBField function:
Please select SLOT1, SLOT2, and SLOT3.
Click on the arrows to vote for the correct answer
A. B. C. D. E. F. G.Correct Answers: C, F and H
Power Apps provides the Client API model for model-driven apps for users to implement for their business logic.
The Client API model includes objects and methods that developers can access using Javascript code.
There are four root objects of the Client API model: executionContext - this is an execution object of the model-driven app.
It gives access to the context of the forms and grids.
formContext - provides access to the form object using the executionContext.
gridContext - provides access to the grid (subgrid) on a form.
Xrm - provides access to the global object for operations that do not directly impact UI and data in forms, grids, controls.
Option C is correct because the SLOT1 is executionContext.
Option F is correct because the SLOT2 is getFormContext().
Option H is correct because the SLOT3 is getAttribute().
Here is the HideDOBField function:
<pre class="brush:java;">function HideDOBField(executionContext){
var field = executionContext.getFormContext().getAttribute("dateofbirth");
field.setVisible(false);
}
</pre>
All other options are incorrect.
For more information about model-driven apps Client API model, please visit the below URLs: