Microsoft.Common.CurrentVersion.targets(4678,5): error MSB3027: Could not copy File

Question: How do you resolve the error "Severity Code Description Project File Line Suppression State
Error MSB3027 Could not copy "File.dll" to "bin\Debug\net5.0\File.dll". Exceeded retry count of 10. Failed. The file is locked by: "ProjectName (10532)" ProjectName C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Current\Bin\Microsoft.Common.CurrentVersion.targets 4678 
".

Answer: Chances are that you added something in the editor.config file that is silencing the Warnings or Errors. Follow the instruction below to resolve the issue.

1. Close Visual Studio, then restart it.
2. Clean the Project Solution and build the Solution.
3. Wait until the Background tasks are complete running then rebuild the Project Solution again.

MSB3027 Build Error


Edit this Article
e-book asp.net Core 3.1 asp.net mvc asp.net core errors asp.net web forms asp.net core tutorial MSB3027 .NET 6 published
Was this page helpful?
Yes Yes! this solution to the problem was helpful. No No! this solution to the problem was not helpful.. Leave ErnesTech Feedback.Feedback
If you log in, you will be notified when someone leaves a comment.

Other users would like to know if this solution helped you.

Your Session is Ending
Login to Continue

© 2021 - ErnesTech - Privacy