CRM 2011 – Quick way to find a guid using a CRM form

Sometimes when I am coding I need the guid of an account, contact etc so I can put it in my code and retrieve one account.

The quickest way I have found to get this from CRM is to go into the account form or the form you want the guid from.

Then press F11, this will maximise the screen.  It also shows the url bar at the top.  You can then

http://crmdevmscrm/Demo/main.aspx?etc=1&extraqs=%3f_gridType%3d1%26etc%3d1%26id%3d%257b92EB0D0E-B22E-E011-9645-00155D106B02%257d%26rskey%3d246505345&pagetype=entityrecord

The guid is the bit after ID and up to the %26

id%3d%257b92EB0D0E-B22E-E011-9645-00155D106B02%257d%26

the b%3d%257 is the first curly bracket { and the %257d%26 is the closing curly bracket, take those out and you are left with the guid

92EB0D0E-B22E-E011-9645-00155D106B02

17 thoughts on “CRM 2011 – Quick way to find a guid using a CRM form

  1. Dominique January 10, 2012 / 12:10 pm

    Thanks for this post it has really been very helpful!

    Just a detail (as it tripped me up), when you say:
    “the b%3d%257 is the first curly bracket”

    You actually mean to say:
    “the %3d%257b is the first curly bracket”

    I was leaving the leading b in the GUID and as a result nothing was working. All good now.

    Thanks again.

    Like

    • Hosk February 13, 2012 / 5:13 pm

      That’s a great way to get the guid

      Like

  2. atlantic city escorts July 14, 2013 / 4:21 am

    Hey! I know this is somewhat off topic but I was wondering if you knew where I could find
    a captcha plugin for my comment form? I’m using the same blog platform as yours and I’m having trouble finding one?
    Thanks a lot!

    Like

  3. Michael Blackburn November 18, 2013 / 3:49 pm

    Press F12 to open the developer console, Click the script tab, and in the bottom right, next to the >> type in:
    frames[0].Xrm.Page.data.entity.getId()

    If you need to call any Xrm function from the context of the javascript console, you can do so by prefacing it with frames[0].

    Like

    • Dominique December 4, 2013 / 9:15 am

      @Michael, thanks for that tip. We’ve been migrated to CRM 2013 and the GUID is no longer displayed in the URL! Your tip worked for me (but only in Internet Explorer).

      Like

    • Donald June 9, 2015 / 4:09 pm

      Nice, thank you!

      Like

  4. Jake January 31, 2014 / 8:22 pm

    The Javascript thing didn’t work for me in 2013, frames[0].Xrm.Page.data was null. I just selected the “email a link” option from the More Actions “…” button at the top of the form. Everything between &id%7b and the next %7b is the GUID.

    Like

    • Hosk February 3, 2014 / 9:35 am

      if you start debugging and then press F12 and then type
      frames[0].Xrm.Page.data.entity.getId()

      you will get the guid. IT worked for me on an account record

      Like

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.