web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Lookup Field Attribute

(0) ShareShare
ReportReport
Posted on by 545

Hi All, 

   In account form we added a lookup called state, the state has name & code which can be seen in lookup for ex. state name Alabama & code is AL

lookup.PNG1.PNG

, now our requirement is when we select "Alabama" AL should be displayed in Lookup attribute.  now Alabama is Displaying in state attribute as below.

5417.lookup.PNG

*This post is locked for comments

I have the same question (0)
  • Verified answer
    Chadi Tannous Profile Picture
    1,039 on at

    crm by default displays the primary field of the entity and you can't change it unless you write a javascript that calls a webapi to get the value "AL" and replace the lookup value

  • Suggested answer
    Aric Levin - MVP Profile Picture
    30,190 Moderator on at

    In your State entity, you will need to change the fields, so that the default field is the abbreviated name, and the full name is on the other field (State Name).

    After you make that change, you will need to go into your Views, and under Quick Find, select the Add Find Columns and make sure that both the Abbreviated Name columns and the State Name columns appear.

    You can probably write a simple On-Demand workflow to change the values of these fields, just make sure that the length of the field is appropriate (not just 2 characters). You can modify the length after you run the workflow.

    You do have the option of changing the displayed value of the selected record in the lookup using webapi and JavaScript, but that will probably be an overkill. Fix it once, and you should be good to go.

  • Verified answer
    Henry J. Profile Picture
    5,237 on at

    Agreed, but I would do an export / import in Excel to switch values instead of a workflow

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans