更改代码Visual Studio 2019之后编译错误

时间:2019-05-08 06:43:44

标签: c# .net visual-studio

我有一个问题,如果每次更改代码都调试我的代码,则会出现编译错误。 每当我重新启动服务器时,一切都会再次运行。

(0,0): error : Cannot create file: C:\Users\alex\AppData\Local\Temp\Temporary ASP.NET Files\vs\a9393033\9993fb91\App_Code.pdb. 
The process cannot access the file because it is used by another process.

我的设置:

  • Visual Studio社区2019 v16.0.2
  • .NET v4.0.30319

1 个答案:

答案 0 :(得分:1)

如果您正在使用ASP.NET,请尝试删除web.config文件中的optimizeCompilations="true"属性。另外,请确保您已安装VS的最新更新。