Question: in model driven apps, when retrieving records this gives me the value, Xrm . WebApi.retrieveRecord ( arb _ smartauditcustomers, customerId, ? $select =

in model driven apps, when retrieving records this gives me the value,
Xrm.WebApi.retrieveRecord("arb_smartauditcustomers", customerId, "?$select=arb_customerid")
but this doesn't work for ownerid. Is there any workaround.
Xrm.WebApi.retrieveRecord("arb_smartauditcustomers", customerId, "?$select=ownerid")
i tried - ownerid.id
As I want to compare visit's owner to customer's owner.
If they match only then can edit a field.
i can get -
// Get the current user's ID
var currentUserId = Xrm.Utility.getGlobalContext().userSettings.userId.replace("{","").replace("}","");
// Get the record owner's ID
var recordOwner = formContext.getAttribute("ownerid").getValue();
I want to Retrieve an Owner Lookup.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!