CRM 2013: Error Custom Workflow Assembly Profiler - plugins

I'm trying to debug my custom workflow assembly using the plugin registration tool for the first time. We are using CRM 2013 on-premise version.
However in setting up the profiler, I got this error below about my mismatched version of 'Microsoft.Xrm.Sdk.Workflow'.
Unhandled Exception: System.IO.FileLoadException: Could not load file or assembly 'Microsoft.Xrm.Sdk.Workflow, Version=5.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)........................
I see that my Microsoft.Xrm.Sdk.Workflow version in the reference property is actually 5.0.0.0. However when I delete and re-add the reference (from the CRM 2013 SDK), then it shows a different version 5.0.9690.3739.
I read other questions about this, but I don't exactly understand how to synch the correct version together. Could someone please let me know how to do this step-by-step - if I need to change the one on the CRM server.
Notice the difference version between the two pics.

Related

Unable to resolve "Could not load file or assembly" exception in .net framework application

After upgrading the FluentValidation NuGet package in my WPF application from version 11.0.2 to 11.4.0, I began to receive the following error when attempting to execute my test suite:
System.IO.FileLoadException
HResult=0x80131040
Message=Could not load file or assembly 'System.Threading.Tasks.Extensions, Version=4.2.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)
Source=FluentValidation
My NuGet packages folder contains the system.threading.tasks.extensions package for versions 4.4.2 and 4.5.4, but not 4.2.0.0.
I am not sure why I am getting this error, or how to resolve it.
I have reviewed the answers to questions by others having similar problems, but without finding a solution.

Crystal Reports Nuget 13.0.4001 generates an log4net error

Our Visual studio project is a 64-bit website which requires the crystal reports runtime installed. We would like to include nuget packages to avoid installing the runtime.
I installed the CrystalReports.Engine nuget and 16 nuget/references are also applied including log4net v1.2.10. The project files reference "Include="log4net, Version=1.2.10.0, Culture=neutral, PublicKeyToken=1b44e1d426115821". This is a pretty old version of the log4net.
When I run our website and try to generate a report, I get the exception "Could not load file or assembly 'log4net, Version=1.2.10.0, Culture=neutral, PublicKeyToken=692fbea5521e1304' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040...". It appears that the libraries are looking for the 32-bit version of log4net.
The nuget packages include 13.0.30.3805, not the latest 13.0.32 libraries. After doing some searching on-line, I am concerned that these nugets are not SAP generated nugets.
This leads me to a few questions:
Are these SAP Crystal Reports nugets?
How do they distinguish between 32-bit and 64-bit projects?
Why are these nugets not using the latest version of the libraries.
How do I resolve this error? (everything I have tried, doesn't fix the problem)

how to get nuget unity

I referred to this one
https://learn.microsoft.com/en-us/visualstudio/cross-platform/unity-scripting-upgrade?view=vs-2017#taking-advantage-of-net-compatibility
i attempted to get nuget npgsql and microsoft office
but this error is occured.
Assembly 'Assets/Plugin/Microsoft.Office.Interop.Excel.dll' will not be loaded due to errors:
Unable to resolve reference 'office'. Is the assembly missing or incompatible with the current platform?
Reference validation can be disabled in the Plugin Inspector.
Unable to resolve reference 'Microsoft.Vbe.Interop'. Is the assembly missing or incompatible with the current platform?
it was same to happen exactly like npgsql
how to get nuget in unity
You might want to check out this asset: https://github.com/GlitchEnzo/NuGetForUnity

Dynamics Plugin throwing "Could not load file or assembly" error

I have a Dynamics365 Plugin which references a Nuget written by me. The build and the registration of the Plugin works and also the merge of all Libraries worked.
When the Plugin is triggered I get the following error:
Error 'System.IO.FileNotFoundException: Could not load file or assembly
'CustomNuget.Xrm.Common.XYZ, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its
dependencies. The system cannot find the file specified.
The Assembly mentioned in the above error is the Nuget included in the Plugin.
What I know for sure is that this exception is thrown from within a Method which is contained in the above mentioned Assembly (Nuget).
When I check the plugin assemby with ILSpy everything looks ok.
How can this be that an exception is telling me the assembly was not found but the error was thrown exactly from this assembly??
Does anybody have an idea?

Changed Entity Framework v6 to Entity Framework v4.4 - getting error

I have created an ASP.NET MVC application and my Entity Framework version is 6.0.0, but I want Entity Framework version 4.4.0.
I have referenced version $.4.0 dll and also changed the version in package.config.
I am getting this error:
"Severity Code Description Project File Line Error CS1705 Assembly
'Microsoft.AspNet.Identity.EntityFramework' with identity
'Microsoft.AspNet.Identity.EntityFramework, Version=2.0.0.0,
Culture=neutral, PublicKeyToken=31bf3856ad364e35' uses
'EntityFramework, Version=6.0.0.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089' which has a higher version than
referenced assembly 'EntityFramework' with identity 'EntityFramework,
Version=4.4.0.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089' Final c:\users\navya\documents\visual
studio 2015\Projects\Final\Final\Models\IdentityModels.cs
Please let me know where I have to make changes when I change my Entity Framework versions in my reference.
Simply put - you can't do that. Identity library was compiled against EF6 and it won't work with lesser version. Upgrade path from 4 to 6 lists breaking changes that will not let you use v4 in any scenario.
You can get the source code, change EF version there, adjust source code to work with v4, build binaries, reference the binaries in your project directly without NuGet package => profit (or rather a step back and a maintenance nightmare)
Or you can build your own implementation of IUserStore that relies on EF4 and make Identity use your implementation.
Other than that you are out of luck. You shouldn't really use EF4, but I suspect this is not your decision to make.