Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Get attribute value from entities CRM online

(0) ShareShare
ReportReport
Posted on by

Hi all, I use web service to get attributes, but always from the same entity where the page is when the web service is executed.

I use:  Xrm.Page.getAttribute("attribute_name").getValue();

But what I want to do is for example execute a web service in quote entity and get attributes from opportunity entity, or product quote, or any other entity ....

Anyone knows how can I do this? I´m using CRM 2016 online.

Thanks a lot,

Idoia

*This post is locked for comments

  • Suggested answer
    Mahendar Pal Profile Picture
    45,095 on at
    RE: Get attribute value from entities CRM online

    Hello,

    You can't get attributes from other entity without making service when working with code. Not sure what is your actual requirement, in case you have requirement to show some addition fields from related entity which is related to 1:N relationship you can use quick view form. You can read more details here:

    technet.microsoft.com/.../dn531145.aspx

    Hope it will help.

    Thanks

  • Community Member Profile Picture
    on at
    RE: Get attribute value from entities CRM online

    Yadnyesh, Vijay and Himbap thanks for all you answer, probably all your answer are correct, but unfortunately i don´t have the enough knowledge to do it, I´m new in crm, I have check the resources you mentioned but I coulnd´t resolve my problem.

    I thought maybe there was an easy way to do that like we use :

    Xrm.Page.getAttribute("attribute_name").getValue();

    just in one js sentence can indicate the instance we want instead 'Page'.

    Maybe using fetchXML I can work with attributes of other entities?

    Thanks a lot

  • Verified answer
    Mahendar Pal Profile Picture
    45,095 on at
    RE: Get attribute value from entities CRM online

    Hello,

    Xrm.Page.getAttribute("attribute_name").getValue(); Here you are not using web service call. You can write OData or Web API to get required entity records.

    Download CRK SDK you will see sample question there, you can also look sample code in our blog http://himbap.com/blog

    You can also refer this tool as suggested by others: crmrestbuilder.codeplex.com

    Thanks

  • Verified answer
    Kumar Viju Profile Picture
    1,026 on at
    RE: Get attribute value from entities CRM online

    Hi,

    You can use tool to generate the query and start referring SDK for better Understanding ( Client Side Scripting )

    crmrestbuilder.codeplex.com

    msdn.microsoft.com/.../mt593051.aspx

    www.inogic.com/.../querying-data-in-microsoft-dynamics-crm-2016-using-web-api

  • Verified answer
    Yadnyesh Kuvalekar Profile Picture
    4,102 on at
    RE: Get attribute value from entities CRM online

    Here is my blog which exactly explains solution for your scenario.

    themscrmexpert.wordpress.com/.../get-lookup-fields-data-on-child-form-using-javascript-without-querying-the-record

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,850 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 231,723 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156 Moderator

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans