Reputation: 311127
I had installed VS11beta and subsequently uninstalled it. Now, my old VS2010 installation is not working as expected.
What I don't understand is why it's saying I should retarget from version 4.0 to version 4.
A similar message pops up in the build output:
C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(847,9): warning MSB3644: The reference assemblies for framework ".NETFramework,Version=v4.0" were not found. To resolve this, install the SDK or Targeting Pack for this framework version or retarget your application to a version of the framework for which you have the SDK or Targeting Pack installed. Note that assemblies will be resolved from the Global Assembly Cache (GAC) and will be used in place of reference assemblies. Therefore your assembly may not be correctly targeted for the framework you intend.
I have repaired my installation of Windows SDK 7.1, which includes the .NET framework 4.0. It doesn't seem to have helped.
Visual Studio 2010 now crashes when I perform a build too.
Is there some explanation for this, and better yet a way to repair my VS2010 without completely uninstalling and reinstalling it?
Sure wish I'd had the common sense to install the beta in a VM!
Upvotes: 1
Views: 714
Reputation: 35870
.NET 4.5 is an in-place update of 4.0. Likely the "4" or "4.0" version of .NET on your computer is different despite uninstalling Visual Studio. If your 2010 projects were created for "4" before VS 2012, that version of "4" is not available anymore--explaining the message. You could try uninstalling and re-installing .NET 4. if you want to avoid retargetting.
Upvotes: 2