Not sure how even that could be possible, but I have got this error message:
That happened after I've:
Warning 3 The primary reference "System.Web.Mvc, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL" could not be resolved because it has an indirect dependency on the framework assembly "System.Data.Linq, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" which could not be resolved in the currently targeted framework. ".NETFramework,Version=v4.0". To resolve this problem, either remove the reference "System.Web.Mvc, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL" or retarget your application to a framework version which contains "System.Data.Linq, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089".
I bet the solution is banal, but it must be that its Friday afternoon.
By the way, I have also VS 2008, MVC 1, MVC 2, all .NET framework versions installed and functional.
Update 1: In fact, I have exactly the same problem with MVC 2 projects targeting .NET 4.
Update 2: I feel that this is somehow related - I do really miss System.Data.Linq.dll in the folder C:\Program Files\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0
(though System.Data.Linq.xml is present)
I reinstalled .NET 4 framework but that didn't fix the problem.
The ASP.NET MVC framework is a lightweight, highly testable presentation framework that (as with Web Forms-based applications) is integrated with existing ASP.NET features, such as master pages and membership-based authentication. The MVC framework is defined in the System.
The main difference between ASP.NET Core and ASP.NET MVC 5 is their cross-platform approach. ASP.NET Core can be used on Windows, Mac, or Linux, whereas ASP.NET MVC 5 can only be used for applications on Windows.
Just had a similar problem (unable to add a reference) with a different dll. Clearing the list of recently added references did help.
Manually uninstall MVC3, Download Microsoft Web Platform Installer and reinstall MVC3 through WPI - that usually does a pretty good job of ensuring prerequisites are present.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With