简体   繁体   中英

VS2015 Unable to Create New Windows 10 UWP Project or Build Existing Windows UWP Samples

When I try to create a new Windows 10 UWP, or open or build existing samples or projects, I get the following error:

The imported project "C:\\Program Files (x86)\\MSBuild\\Microsoft\\WindowsXaml\\v14.0\\8.2\\Microsoft.Windows.UI.Xaml.CSharp.targets" was not found. Confirm that the path in the declaration is correct, and that the file exists on disk

I am running VS2015 Enterprise on Windows 10 Pro. Windows 10 SDK (10240) and Emulators installed. Have re-installed VS2015 several times without luck. There is no v14.0\\8.2 folder on my machine. Tried to copy the v14.0\\8.1 folder to create v14.0\\8.2 folder but this only allows you to load the project or create new ones, but build fails. This is driving me crazy.

Note: An earlier install of same VS2015 ISO and SDK on Windows 10 Enterprise Evaluation was running successfully until I had to re-format a few days ago when I upgraded my Windows 7 to Windows 10 Pro. I have now also tried to install a clean copy of Windows 10 Enterprise, re-install VS2015 with SDK and emulators, and yet no luck. Same error keeps repeating.

Any suggestions on where/how to create the v14.0\\8.2 folder would be appreciated.

The solution is to navigate to Control Panel | Uninstall a program and to select Visual Studio 2015. This allows you modify you existing Visual Studio 2015 installation. When you install, it is recommended to select the "install all" features which added the templates.

This blog should be helpful for you.

Besides, what's the exact version of VS2015 and Win10 you installed?

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM