Severity Code Description Project File Line Suppression State
Error NETSDK1004 Assets file ‘E:\DemoTest\Demo\Demo\obj\project.assets.json’ not found. Run a NuGet package restore to generate this file. Demo C:\Program Files\dotnet\sdk\3.0.100\Sdks\Microsoft.NET.Sdk\targets\Microsoft.PackageDependencyResolution.targets 234

这就是.net standard的包没还原,从而导致连System命名空间都找不到的错误。

解决步骤:

  1. 检查是否安装NETStandard.Library包,
  2. 检查Visual Studio包管理的设置问题。
    Visual Studio 2015默认是勾上的, 而2017和2019有可能没有勾上。

Assets file 'E:\*\*\*\obj\project.assets.json' not found.Run a NuGet package restore to generate
Assets file 'E:\*\*\*\obj\project.assets.json' not found.Run a NuGet package restore to generate

相关文章:

  • 2021-08-15
  • 2021-09-11
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-01-29
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-12-29
  • 2021-07-13
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案