There may be some problems in the build as projects copy themselves and their dependencies (other projects, references, NuGet packages, etc) into the same output folder.
This error occurs because you have added files to source control that
should not be in there. Therefore it is downloaded from TFS and marked
as read only.
Take a look at this similar question: Error VSP1737: File could not be opened due to sharing violation
You could use a .tfignore file
. You will have to manually remove all of the files that have already been added. How to please refer my reply here.
Then check for *.dll and other binaries, including *.vsp files and
remove them from source control.
There are two types of binaries:
- References - these should be done using Nuget and never included in source control or added manually.
- output/generated - No generated files should be added to source control.
How to use Nuget to manage dll, take a look at below tutorials: