Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

Automatically relate the child account with parent account

Posted on by 932

How we can do the thing like if user select any child account  and automatically related parent account will be selected?

*This post is locked for comments

  • RE: Automatically relate the child account with parent account

    Thanks Radu

  • Verified answer
    Radu Chiribelea Profile Picture
    Radu Chiribelea 6,667 on at
    RE: Automatically relate the child account with parent account

    Hi Shakti,

    Please find below some links that can help you start:

    msdn.microsoft.com/.../hh771584.aspx

    msdn.microsoft.com/.../gg309637.aspx

    www.tutorialspoint.com/.../microsoft_crm_jscript_web_resources.htm

    community.dynamics.com/.../187254

  • RE: Automatically relate the child account with parent account

    I am beginner in dynamics so please can you told me that in details

  • RE: Automatically relate the child account with parent account

    Thanks Radu

  • Verified answer
    Radu Chiribelea Profile Picture
    Radu Chiribelea 6,667 on at
    RE: Automatically relate the child account with parent account

    Hi Shakti,

    If you want to do this on the page, one idea that you could try is following:

    1. Add an OnChange Event Handler on the Account field

    2. When child account is selected, create a Retrieve Request using the WebAPI - you can do this via the REST Builder github.com/.../CRMRESTBuilder - to retrieve the parent account.

    3. If the query returns results, then set the value of the account field - see community.dynamics.com/.../javascript-set-lookup-details

    With this approach, however you'd need to check and make sure you are not entering a loop - so probably you should test and see how it behaves.

    Another think you can try is to create an additional lookup, where you select the Child Account and then based on that, populate the original lookup with the parent.

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,214 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans