Associate one lookup to another crm 2011

Posted on 2014-08-08
Last Modified: 2014-11-14
Hi everyone

I am trying to display a certain view in a lookup depending on what value is in another entity lookup.


In "Case Entity", I have a lookup field called "Worktype"
I have an Entity called "Link from Worktype to Time Activity", this has 2 lookup fields in there for many to many relationship, from Time Activity and Worktype.
I have an entity/activity called Time Spent that a user create a new record everytime they work on a case.
I have views that returns all Time Activity, that is linked to "Worktype" of the "Case"

In Time Spent Entity, I have a mapping to "Case", and a lookup field to Time Activity. I there anyway, if so how, to only display (when they click the lookup field) the "Time Activity View" needed for the "Worktype" of the "Case" without the user having to manually dropdown the list and select.

I hope the above makes sense.

Any help would be very much appreciated.

Question by:Bakersville
    LVL 19

    Accepted Solution


    You have to work on javascript to solve this. You can use addCustomView() method from Xrm.

    Please check below solution for reference.
    LVL 1

    Author Comment

    Hi Rikin

    Thank ever so much for this.

    This does look like a great solution, however, the GUID I am after is from another lookup in an entity within the lookup entity linked on the entity, unless there is a way mapping it to the top entity from the lookup second entity.

    I really hope this makes sense.

    LVL 19

    Expert Comment

    by:Rikin Shah

    You can get the GUID from related entity as well. Try to get the GUID from the retrieve method and you can move ahead.
    LVL 1

    Author Closing Comment

    Got it working thanks

    Featured Post

    Enabling OSINT in Activity Based Intelligence

    Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

    Join & Write a Comment

    This is a walkthrough guide I wrote whilst upgrading my on-premise MS Dynamics CRM 3.0 deployment to 4.0. This covers the actual installation of the product to a working level for my system, I ran into a lot of issues that the steps below fixed so h…
    On Sep 22nd 2014 Microsoft released Update Rollup 1 for Microsoft Dynamics CRM 2013 Service Pack 1 and back in July Update Rollup 3 was released.  So we now have:   Update Rollup 1Update Rollup 2Update Rollup 3Service Pack 1Update Rollup 1 for S…
    Internet Business Fax to Email Made Easy - With eFax Corporate (, you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
    In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor ( If you're interested in additional methods for monitoring bandwidt…

    746 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    18 Experts available now in Live!

    Get 1:1 Help Now