MahApps / MahApps.Metro

A framework that allows developers to cobble together a better UI for their own WPF applications with minimal effort.
https://mahapps.com
MIT License
9.32k stars 2.45k forks source link

Unable to build project solution (Release 1.6.5 under VS 2019) #3501

Closed erotavlas closed 5 years ago

erotavlas commented 5 years ago

I tried to build and run project solution from release 1.6.5 in VS 2019 and it complains of the following


Severity    Code    Description Project File    Line    Suppression State
Error   MSB3644 The reference assemblies for framework ".NETFramework,Version=v4.7" 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.  MahApps.Metro.Demo  C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Current\Bin\Microsoft.Common.CurrentVersion.targets   1183    

Capture

Even though I have .Net 4.7 installed

Also I tried to download the latest .NET Core 3.0 preview as indicated in the info for developers, and I tried to open the latest development branch, without success

1Capture

So not really sure what has happened here. I used to be able to open and run the previous releases 1.6.x in visual studio but not anymore.

punker76 commented 5 years ago

@erotavlas Have you really installed the .Net 4.7 SDK?

andyb1979 commented 5 years ago

VS can be a pain. Is there a global.json file in the root of the directory? I recently had this issue with a project I'm working on and adding global.json to specify SDK locations solved it.

punker76 commented 5 years ago

@andyb1979 I don't know how to add multiple sdk specifications inside the global.json. @erotavlas I would suggest to install also the .NET Framework 4.7 Developer Pack to build the solution.