This is one that’s tripped me up a couple of times, somewhat randomly. I’ve never really tracked down what causes the issue – perhaps moving development between a Mac and an PC, but either way its something that doesn’t require a lot of solving.
The error in question reads…
A numeric comparison was attempted on "$(TargetPlatformVersion)" that evaluates to "" instead of a number,
in condition "'$(TargetPlatformVersion)' > '8.0'".
C:\Program Files (x86)\MSBuild\12.0\bin\Microsoft.Common.CurrentVersion.targets
…and is generally accompanied by a project within Visual Studio failing to load.
Without knowing exactly what the problem is, I have tracked it down to something going wrong with ReSharper. So to get passed the error:
- Disable ReSharper
- “Suspend Now”
- You may then need to restart Visual Studio
- Your solution should now load just fine.
- You should be able to no resume ReSharper, and everything will be working just fine