It is really Visual Studio itself that is keeping the document open, and a resulting task can't overwrite it. The error simply occurs, and after that won't leave until you restart Visual Studio, which will make the lock on the record go.
Some solutions provided for this is pre-build scripts that deletes the locked .exe file so that the debug hosting process could be killed or using Task Manager to kill it but this is all temporary solution.
The error initiated when changes to projects AssemblyInfo.cs was done
I did above to get automatic versioning actual code was like this:
Presently in the event that you replace the last two digits of the gathering form with a asterisk, at that point Visual Studio will replace it with new values each time you build. The values it uses are really founded on the present date and time. This appears to be valuable, since now you won't be left with adaptation 220.127.116.11 and Visual Studio increases forms each time you build, so you don't need to do this physically.