VS2010: Incompatible link when trying to add a link

VS2010: In my new project, every time I try to add a link to any of my other projects or, in this case, to MySql.Data ..., I get the error "Incompatible link" - "In to add it, you must first change the project goal to a compatible environment "

My target is installed on .NET 4, and regardless of whether there was a link that I am trying to add or not installed in .NET 4, I still get an error. Anyone have any suggestions? Thanks

+8
reference visual-studio-2010 projects-and-solutions
source share
5 answers

Well, I'm not sure what the problem is, but if I go to the physical file to add the link instead of using the Recent or other dialogs in the Add Links window, everything will be fine. I never figured out why the other way stops working for me.

+11
source share

I had the same problem. The problem was resolved by adding a link to the compiled dll file. This would work for me, but I wondered why it worked, and the link to the project does not.

I checked the project I would like to use. Two more projects are mentioned in this project. I resolved the error by doing the following:

  • Added project (x) to my solution, which I liked to reference
  • Added projects (ref1 and ref2), which are indicated in the reference project (x).
  • Added link (x) to consumer project
  • An error has occurred.

Hope this helps you in the future.

Hi,

Stephen

+2
source share

You have removed the obvious reason for getting this error. It remains to add the assembly that was created to run on another target platform. Like Silverlight or Windows Phone. You cannot mix these platforms; they run with a different version of the CLR and mscorlib. There is no shortcut for this, you will have to rebuild the assembly.

+1
source share

J. Benjamin,

We have created a tool that will help you achieve your goal. Muse VSReferences will allow you to add a global assembly caching link to the project from Add GAC Link.

enter image description here

Hi

0
source share

I had the same problem with my .Net assembly compiled in .Net Framework 4.0 After a lot of searching, I find the problem ... there was a link to my case that I created in the Windows registry to see my assembly on the link screen in Visual Studio : HKEY_CURRENT_USER \ Software \ Microsoft.NETFramework \ v2.0.50727 \ AssemblyFoldersEx \ BNB.Seguranca.V2.0

the value was with empty space at the beginning of the registry value, which caused a problem to find the assembly in the correct folder.

0
source share

All Articles