在VS2012 C#项目的构建过程中,我不断收到此错误
Error 41 Could not copy "obj\Debug\WeinGartner.WeinCad.exe" to
"bin\Debug\WeinGartner.WeinCad.exe".
Exceeded retry count of 10. Failed.
Error 42 Unable to copy file "obj\Debug\WeinGartner.WeinCad.exe" to
"bin\Debug\WeinGartner.WeinCad.exe". The process cannot access the file
'bin\Debug\WeinGartner.WeinCad.exe' because it is being used by another
process.
现在我想通了
Weingartner.WeinCad.vhost.exe
有效(有时),但这让我感到不安。有什么办法可以阻止这种情况的发生?
我的调试器设置是
最佳答案
我在Visual Studio 2013中遇到了类似的错误消息。
通常,我发现当调试过程由于异常而停止时,就会发生这种情况。
当clean + build无法为我解决此问题时,请执行以下操作以取得成功:
bin
和obj
文件夹以及自Visual Studio 2003以来,就存在此“错误”。
最后,我还发现我通常可以通过简单地重命名可执行文件然后将其删除来解决此问题。