You are examining code written by another developer that is not functioning correctly

HOTSPOT

You are examining code written by another developer that is not functioning correctly.

There are no other JavaScript or business rules in use on the form.

This code is properly registered to the OnChange event of the telephone1 field on an account entity form. The main operation is to update the primary contact’s phone number when the account phone number changes.

The primary contact field is a lookup. (Line numbers are included for reference only.)

For each of the following statements, select Yes if the statement is true. Otherwise, select No. NOTE: Each correct selection is worth one point.

Answer:

Explanation:

Graphical user interface, text, application

Description automatically generated

Box 1: Yes

getFormTyp gets the form type for the record.

Form type 2 is Update.

Note: Syntax: formContext.ui.getFormType();

Return Value

Type: Number

Description: Form type. Returns one of the following values

RETURN VALUE

Value Form type

0 Undefined

1 Create

2 Update

3 Read Only

4 Disabled

6 Bulk Edit

Box 2: Yes

Xrm.WebApi.updateRecord Return Value: On success, returns a promise object containing the values specified earlier in the description of the successCallback parameter.

Note:

Syntax: Xrm.WebApi.updateRecord(entityLogicalName, id, data).then(successCallback, errorCallback);

Where errorCallback: A function to call when the operation fails.

An object with the following properties will be passed:

errorCode: Number. The error code.

message: String. An error message describing the issue.

Box 3: No

It will displayed even if the update fails.

Latest PL-400 Dumps Valid Version with 171 Q&As

Latest And Valid Q&A | Instant Download | Once Fail, Full Refund

Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments