Question

I need to take data from a Dynamic CRM 2013 tables using web services.

In a Console Application I used microsoft.xrm.sdk.dll and it was so easy to make query using QueryExpression.

But now I need to do the same thing and represent data on an Application Page for SharePoint 2013 Project. And I used the same way, but there is exception:

Could not load file or assembly "Microsoft.Xrm.Sdk, Version=5.0.0.0, Culture=neutral, PublicKeyToken=********" or one of its dependencies. The system cannot find the file specified.

Why is it happening?

Was it helpful?

Solution

In your VS project --> expand References --> click on the Microsoft.Xrm.Sdk assembly --> lock at it's properties and make sure it's set to Copy Local = true.

If that still doesn't work, try adding the Microsoft.Xrm.Sdk assembly to the SharePoint server GAC. On the server, run gacutil -i [path to assembly]

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top