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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Suggested Answer

Can't access CRM 2013 (V 6.1) with latest XrmTooling.CoreAssembly (9.1.0.79)

(0) ShareShare
ReportReport
Posted on by 5

Does the current version of the Dynamics 365 SDK support connectivity to CRM 2013?  Here's my code I'm trying to execute:

string crmConnectionString = String.Format("AuthType=AD;Domain={0};Username={1};Password={2};Url={3}", domain, username, password, "">">http://myserver/myorg");
CrmServiceClient crmServiceClient = new CrmServiceClient(crmConnectionString);
Guid userid = ((WhoAmIResponse)crmServiceClient.Execute(new WhoAmIRequest())).UserId;

After calling the constructor, crmServiceClient.LastCrmError is this:

Unable to login to Dynamics CRM, Error was : The formatter threw an exception while trying to deserialize the message: There was an error while trying to deserialize parameter schemas.microsoft.com/.../Services:request. The InnerException message was 'Error in line 1 position 518. Element 'schemas.microsoft.com/.../Services:request' contains data from a type that maps to the name 'schemas.microsoft.com/.../Contracts:RetrieveCurrentOrganizationRequest'. The deserializer has no knowledge of any type that maps to this name. Consider changing the implementation of the ResolveName method on your DataContractResolver to return a non-null value for name 'RetrieveCurrentOrganizationRequest' and namespace 'schemas.microsoft.com/.../Contracts'.'. Please see InnerException for more details.
The formatter threw an exception while trying to deserialize the message: There was an error while trying to deserialize parameter schemas.microsoft.com/.../Services:request. The InnerException message was 'Error in line 1 position 518. Element 'schemas.microsoft.com/.../Services:request' contains data from a type that maps to the name 'schemas.microsoft.com/.../Contracts:RetrieveCurrentOrganizationRequest'. The deserializer has no knowledge of any type that maps to this name. Consider changing the implementation of the ResolveName method on your DataContractResolver to return a non-null value for name 'RetrieveCurrentOrganizationRequest' and namespace 'schemas.microsoft.com/.../Contracts'.'. Please see InnerException for more details.Unable to Login to Dynamics CRM
Unable to Login to Dynamics CRMOrganizationWebProxyClient is null
OrganizationWebProxyClient is null

I've testing this version against and CRM 2015, 2016 and Dynamics 365 and the above code works fine.  I couldn't find any backwards compatibility info on this - does anybody know if this is supported?

Thank you,

Joe

I have the same question (0)
  • Suggested answer
    Charan Raju C R Profile Picture
    7 Moderator on at

    Hi jklug,

    I don't think it supports if your CRM version is V6.1.1. Please refer below link.  

    community.dynamics.com/.../dynamics-365-sdk-backwards-compatibility

  • jklug Profile Picture
    5 on at

    Charan,

    Thank you for your response. I've seen this article, and although I read it differently as all the SDK client versions show support for Dynamics CRM versions 6.x.  It is from 2016 though and doesn't cover version 9.x of the SDK.

    Joe

  • Suggested answer
    jklug Profile Picture
    5 on at

    I have found a solution to this. In my code I'm using the CrmServiceClient constructor that takes a connection string:

    CrmServiceClient crmServiceClient = new CrmServiceClient(crmConnectionString);

    For some reason this doesn't work for CRM 2013, even if I sent the AuthType = AD in the connection string.  I changed this to use this constructor:

    public CrmServiceClient (System.Net.NetworkCredential credential, Microsoft.Xrm.Tooling.Connector.AuthenticationType authType, string hostName, string port, string orgName, bool useUniqueInstance = false, bool useSsl = false, Microsoft.Xrm.Sdk.Discovery.OrganizationDetail orgDetail = default);

    This one works with CRM 2013 through Dymamics 365.

    Joe

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
11manish Profile Picture

11manish 52

#2
Manoj - ManoVerse Profile Picture

Manoj - ManoVerse 43 Super User 2026 Season 1

#3
Ayesha Wajahat Profile Picture

Ayesha Wajahat 14

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans