Can I use FSharp.Data with .NET 4.0? - c#

I have Visual Studio 2010 and .NET 4.0. When I try to use FSharp.Data.dll 2.0.9 in my C# project, it gives the warning:
The primary reference "FSharp.Data" could not be resolved because it
has an indirect dependency on the .NET Framework assembly
"FSharp.Core, Version=4.3.0.0, Culture=neutral,
PublicKeyToken=b03f5f7f11d50a3a" which has a higher version "4.3.0.0"
than the version "4.0.0.0" in the current target framework.
Update:
I downloaded and added FSharp.Core version 4.3.0.0 dll to the project reference. It now has one more error message:
The primary reference "FSharp.Core, Version=4.3.0.0, Culture=neutral,
PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL" could not
be resolved because it has a higher version "4.3.0.0" than exists in
the current target framework. The version found in the current target
framework is "4.0.0.0".

Related

Visual studio shows Error while connecting to MySQL

Warning 3:
The primary reference "MySql.Data, Version=8.0.12.0, Culture=neutral,
PublicKeyToken=c5687fc88969c44d, processorArchitecture=MSIL" could not
be resolved because it has an indirect dependency on the assembly
"Google.Protobuf, Version=3.5.1.0, Culture=neutral,
PublicKeyToken=a7d26565bac4d604" which was built against the
".NETFramework,Version=v4.5" framework. This is a higher version than
the currently targeted framework
".NETFramework,Version=v4.0,Profile=Client".demo
Get a older Version
6.8.8 works out for me al the time

asp.net Deleted Framework

Warning 28 The primary reference "MySql.Data, Version=8.0.11.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d, processorArchitecture=MSIL" could not be resolved because it has an indirect dependency on the assembly "Google.Protobuf, Version=3.5.1.0, Culture=neutral, PublicKeyToken=a7d26565bac4d604" which was built against the ".NETFramework,Version=v4.5" framework. This is a higher version than the currently targeted framework ".NETFramework,Version=v4.0". MMS
what's this error suppose to mean? plz help
Take a look at the current project properties, there is a target framework. You need to change it to 4.5 or above

c# different versions in same assembly

when i decompilation assembly Microsoft.AspNet.Identity.Core in my project
I got stuck seeing string
#region Assembly Microsoft.AspNet.Identity.Core, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35
d:\Projects\tb\packages\Microsoft.AspNet.Identity.Core.2.2.1\lib\net45\Microsoft.AspNet.Identity.Core.dll
#endregion
In first sting specified version 2.0.0.0
In second string specified version 2.2.1
Which version I use? how could this happen?
2.2.1 is a version of NuGet package Microsoft.AspNet.Identity.Core that contains Microsoft.AspNet.Identity.Core.dll.
2.0.0 is a version of Microsoft.AspNet.Identity.Core.dll.

Microsoft.SqlServer.Smo issue

I have a .NET 2.0 project and I get the following error when I try to compile some projects that use SMO:
The primary reference "Microsoft.SqlServer.Smo, Version=9.0.242.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91, processorArchitecture=MSIL" could not be resolved because it has an indirect dependency on the framework assembly "System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" which could not be resolved in the currently targeted framework. ".NETFramework,Version=v2.0".
To resolve this problem, either remove the reference "Microsoft.SqlServer.Smo, Version=9.0.242.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91, processorArchitecture=MSIL" or retarget your application to a framework version which contains "System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089".
Can someone help. I don't want to move the projects to .NET 3.5 because of this.
Thanks
As the exceptions says the current reference assembly needs .NET 3.5. You must downgrade Microsoft.SqlServer.Smo which support .NET 2.0.

Problem using Managed C++ (.Net 2.0) in .Net 2.0 project in VS2010

I have two projects:
1) a project written in Visual C++ 2005 which targets the .net Framework 2.0.
2) a project in Visual C# 2010 that targets .net framework 2.0 and includes the C++ DLL.
When I build the C# project referencing the C++ assembly, I get errors like:
C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(1360,9): warning MSB3258: The primary reference "ScannerWizard" could not be resolved because it has an indirect dependency on the .NET Framework assembly "mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" which has a higher version "4.0.0.0" than the version "2.0.0.0" in the current target framework.
C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(1360,9): warning MSB3258: The primary reference "ScannerWizard" could not be resolved because it has an indirect dependency on the .NET Framework assembly "System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" which has a higher version "4.0.0.0" than the version "2.0.0.0" in the current target framework.
C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(1360,9): warning MSB3258: The primary reference "ScannerWizard" could not be resolved because it has an indirect dependency on the .NET Framework assembly "System.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" which has a higher version "4.0.0.0" than the version "2.0.0.0" in the current target framework.
C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(1360,9): warning MSB3258: The primary reference "ScannerWizard" could not be resolved because it has an indirect dependency on the .NET Framework assembly "System.Xml, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" which has a higher version "4.0.0.0" than the version "2.0.0.0" in the current target framework.
C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(1360,9): warning MSB3258: The primary reference "ScannerWizard" could not be resolved because it has an indirect dependency on the .NET Framework assembly "System.Security, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" which has a higher version "4.0.0.0" than the version "2.0.0.0" in the current target framework.
C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(1360,9): warning MSB3258: The primary reference "ScannerWizard" could not be resolved because it has an indirect dependency on the .NET Framework assembly "System.Data.SqlXml, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" which has a higher version "4.0.0.0" than the version "2.0.0.0" in the current target framework.
If I make the project 4.0, it doesn't give those errors. Obviously, I shouldn't have to make it target 4.0 to use a 2.0 assembly.
Any idea on how I can fix this?
The C++ project was using the v100 Platform toolset. This makes it depend on 4.0 .NET versions of some libraries. Changing the toolset to v90 solves the problem. You may need to install the v90 toolset if you don't have them...

Categories