Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Retrieving records through the API using C#

(0) ShareShare
ReportReport
Posted on by

Hi,

I'm just starting to explore Dynamics and the API and I'm just wondering how I can retrieve a record through the API without knowing the GUID of the record.

Here's the scenario that I have created so far.  I have created a custom entity that has some fields defined such as Name, Fund Code and a few others.

I have a piece of C# code that queries my source DB for a list of records and then uses the Dynamics API (I'm using late bound n this instance) to load those records into my custom entity.

This all works really well so the next step is to augment the code slightly to check to see if the record already exists in Dynamics and then either update it if it does or create it if it doesn't.  The problem is, is that I don't know what the Dynamics GUID is so I would like to retrieve the record using Fund Code which will be unique.

Could anyone offer any advice on how to achieve this?

Many Thanks!

*This post is locked for comments

  • Community Member Profile Picture
    on at
    RE: Retrieving records through the API using C#

    Many thanks, that's spot on!  I'm just working my way through the API so some of the methods are still a little new to me as I didn't know about the RetrieveMultiple!!

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

Jainam Kothari – Community Spotlight

We are honored to recognize Jainam Kothari as our June 2025 Community…

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard >

Featured topics

Product updates

Dynamics 365 release plans