Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Retrieve Multiple

(0) ShareShare
ReportReport
Posted on by 250

Hello Everyone !

im trying to retrieve a information that is located in a  entity and populate in a field in another other entity but my code its not working can anyone see why ?

function getcep(executionContext) {
var attribute = executionContext.getEventSource();
var CEP = attribute.getValue();

SDK.REST.retrieveMultipleRecords("crd4c_cep", "?$select=crd4c_Logradouro&$filter=crd4c_CEP eq '" + CEP + "'", function (results) {
alert("CEP: " + CEP);
var crd4c_Logradouro = results[0].crd4c_Logradouro.crd4c_Logradouro.value;
Xrm.Page.getAttribute("crd4c_Logradouro").setValue(crd4c_Logradouro);
}, function (error) {
Xrm.Utility.alertDialog(error.message);
}, function () {
//On Complete - Do Something
});
}

*This post is locked for comments

  • Mahendar Pal Profile Picture
    Mahendar Pal 45,095 on at
    RE: Retrieve Multiple

    Hi,

    I will suggest you to debug your code and check if you are getting CEP value correctly and your query is correct. You can also use Rest builder to design and test your query.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Daivat Vartak – Community Spotlight

We are honored to recognize Daivat Vartak as our March 2025 Community…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Kudos to the February Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 292,516 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 231,409 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans