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 :
Microsoft Dynamics CRM (Archived)

unable to get Xrm.Tooling.Connector work C#

(0) ShareShare
ReportReport
Posted on by 2,665

Hi,

We are CRM 2016 onprem(recently upgraded from CRM 2015 onprem).

I am trying to use the new tooling connector in my console application. Previously, for such console apps I used to use Microsoft.Xrm.Client namespace.

Now, with the tooling connector I am getting " Organization cannot be null or empty."

My app.config looks like this:

add name="CRM" connectionString="Url=https://xxxx.xxx.us; Username=xxx\CRMxxx; Password=xxxxxx" />

And here is the code snippet:

CrmServiceClient service = new Microsoft.Xrm.Tooling.Connector.CrmServiceClient(



ConfigurationManager.ConnectionStrings["CRM"].ConnectionString);

return service;

Someone please guide me through this. Thanks for any help!

 

*This post is locked for comments

I have the same question (0)
  • Verified answer
    Clem Profile Picture
    2,541 on at

    Hello,

    Are you onpremise ? according to : msdn.microsoft.com/.../mt608573.aspx

    Can you try adding the following 2 parameters then : AuthType and the domain.

    You have a sample for each scenario in the url above.

    Regards,

    Clément

  • crmprogrammer2013 Profile Picture
    2,665 on at

    It worked. That link was helpful.

    Added domain and organization name at the end of the url.

    Thanks.

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

    Take a look at the article below:

    missdynamicscrm.blogspot.com/.../error-unable-to-login-to-dynamics.html

    Notice the image at the middle with the different connection strings. That should help.

    If not check out the following msdn article:

    msdn.microsoft.com/.../mt608573.aspx

    Hope this helps.

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 Launch!

Jump in, show your community spirit, and win prizes!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Congratulations to the May Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans