“找不到导入的项目。确认<import>声明中的路径是否正确”

时间:2016-07-26 09:26:14

标签: visual-studio-2015

我正在尝试从Visual Studio 2015 Professional上运行示例:https://github.com/Microsoft/Windows-universal-samples/tree/dev/Samples。 但是,当我尝试加载项目CameraFrames.csproj时,我收到以下错误:

  

“导入的项目”C:\ Program Files(x86)\ Windows Kits \ 10 \ bin \ 10.014332.0 \ XamlCompiler \ Microsoft.Windows&gt; UI.Xaml.Common.targets“未找到。确认路径在声明中是正确的,并且该文件存在于磁盘上.C:\ Program Files(x86)\ MSBuild \ Microsoft \ WindowsXaml \ v14.0 \ 8.21 \ Microsoft.Windows.UI.Xaml.Common.targets“

我的系统上存在第二个文件,但第一个文件不存在。 我尝试编辑我的CameraFrames.csproj文件并添加了我系统中存在的文件。但这没用。 (见下文) 第一次变化:     <Content Include="C:\Program Files (x86)\MSBuild\Microsoft\WindowsXaml\v14.0\8.21\Microsoft.Windows.UI.Xaml.Common.Targets"> </Content> 2nd change: (after deleting the first change) <Reference Include= "Microsoft.Windows.UI.Xaml.Common"> <HintPath> C:\Program Files (x86)\MSBuild\Microsoft\WindowsXaml\v14.0\8.21\Microsoft.Windows.UI.Xaml.Common.Targets </HintPath> </Reference>

有什么想法吗?我长期以来一直坚持这个问题。 谢谢!

1 个答案:

答案 0 :(得分:2)

请修复Visual Studio并重新启动PC。问题将得到解决。

我收到错误:“确认声明中的路径是正确的,并且该文件存在于磁盘上。”

我遇到了与Visual Studio 2015相同的问题,Windows 8上的.Net 4.6版本。尝试了很多东西,但最终修复VS工作。 :)

相关问题