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)

Common Data Service SDK

(0) ShareShare
ReportReport
Posted on by 185

Hi All,

Have anybody used CDS SDK?

I am getting an error "

System.IO.FileNotFoundException occurred
HResult=0x80070002
Message=Could not load file or assembly 'System.Configuration.ConfigurationManager, Version=0.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'. The system cannot find the file specified.
Source=<Cannot evaluate the exception source>
StackTrace:
at Microsoft.CommonDataService.Configuration.Loaders.AppConfigLoader.Load()
at System.Lazy`1.ViaFactory(LazyThreadSafetyMode mode)
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Lazy`1.CreateValue()

"

on the highlighted line (see below pic). Can anybody help me to out this problem?

errorrrr.png

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Rawish Kumar Profile Picture
    13,758 on at

    Hi Zeshan,

    try to remove the "system.configuration" from the references and add again. it should be okay.

  • Verified answer
    Community Member Profile Picture
    on at

    Hi Zeshan,

    it seems a known bug, to solve it please install Nuget package for System.Configuration.ConfigurationManager.

    Please let me know.

    If you found the answer helpful, please mark as Verified 

    Join my network on LinkedIn      Follow me on Twitter 

    Thank You & Best Regards

    Francesco Picchi

    Microsoft Dynamics CRM Consultant, Bologna+Milano, ITALY

    Independent Contractor

    http://www.francescopicchi.com

  • Zeshan Khan Profile Picture
    185 on at

    Thanks Francesco. You were right. it fixed now but another error came and this time this seems not a general error.

    "Microsoft.CommonDataService.ServiceClient.Configuration.Exceptions.InvalidConfigurationException occurred

     HResult=0x80131500

     Message=Microsoft/CommonDataService/Connection section missing from the app.config or the Microsoft.CommonDataService.ServiceClient.Extensions.ConfigurationSection section type is not correctly registered. Validate that your app.config has the correct settings per the CDS SDK documentation.

     Source=<Cannot evaluate the exception source>

     StackTrace:

      at Microsoft.CommonDataService.Configuration.Loaders.AppConfigLoader.Load()

      at System.Lazy`1.ViaFactory(LazyThreadSafetyMode mode)

      at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()

      at System.Lazy`1.CreateValue()"

    on the same line. My App.config file is given below:

    app.config-error.png

  • Zeshan Khan Profile Picture
    185 on at

    Thanks Rawish. But removing/adding didn't work.

    It seems installing System.Configuration.ConfigurationManager from NuGet installed in proper project directory.

  • Community Member Profile Picture
    on at

    Hi Zeeshan,
    On this forum https://docs.microsoft.com/en-us/common-data-service/entity-reference/cds-sdk-get-started you made a comment that you are facing the problem of "environment discovery failed". Can you please tell how you resolved that.

    Thanks.

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