I have been using this code to open an look up window it is throwing an error "Uncaught TypeError: Cannot read properties of undefined (reading 'REST'"
Please help me in getting out of this!
var strAccountFilter = "$filter=AccountId eq (guid'" + strAccountId + "')";
//var DefaultViewId = Xrm.Page.getControl("cmc_carrieridaccount").getDefaultView();
parent.SDK.REST.retrieveMultipleRecords("Account", strAccountFilter, getAccountOnSuccess, errorHandler, function () { });
}
function getAccountOnSuccess(result) {
if (result == null || result.length == 0)
return;
var strURL = "_controls/lookup/lookupinfo.aspx?AllowFilterOff=0&DefaultType=11129&DefaultViewId=%7bEA7EB181-7C13-4466-A681-87A22A54A9D9%7d&DisableQuickFind=0&DisableViewPicker=0&IsInlineMultiLookup=0&LookupStyle=single&ShowNewButton=1&ShowPropButton=1&dType=1&mrsh=false&objecttypes=11129&rDependAttr=quote.cmc_accounttoquoteid&rId=";
strURL += "{" + result[0].AccountId + "}&rType=1&relationshipid=cmc_account_cmc_carrier_CarrierIDAccount";
HI,
Use Xrm.WebApi.RetrieveMultipleRecords instead of parent.xrm.sdk.Rest
docs.microsoft.com/.../retrievemultiplerecords
Please mark my answer verified if this is helpful!
Regards,
Bipin Kumar
Follow my Blog: xrmdynamicscrm.wordpress.com/
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,240 Super User 2024 Season 2
Martin Dráb 230,149 Most Valuable Professional
nmaenpaa 101,156