Try our conversational search powered by Generative AI!

Build error: Access to the path 'bin\EPiServer.xml' is denied

Vote:
 

I have a project where I'm seeing this a lot when doing "Rebuild solution":
Error 110 Unable to copy file "\packages\EPiServer.CMS.Core.7.13.3\lib\net40\EPiServer.xml" to "bin\EPiServer.xml". Access to the path 'bin\EPiServer.xml' is denied.

Anyone else in the same boat?

One possible workaround I have found is deleting EPiServer.xml from \packages but I think that's a bit crude.

#121884
May 19, 2015 15:45
Vote:
 

Hi,

Make sure you don't have any locks on the bin\EPiServer.xml. A handy tool is Unlocker, which let you know which programs are locking a certain file.

Regards.

/Q

#121888
May 19, 2015 17:16
Vote:
 

The lock is only there while building, can't seem to find it using Unlocker but I'm fairly certain it's msbuild or Visual Studio that holds it.

This one contains some other workarounds but no real solution:
http://stackoverflow.com/questions/1167608/how-can-i-prevent-visual-studio-from-locking-the-xml-documentation-files-in-the

#121890
May 20, 2015 8:16
Vote:
 

Do you have any custom msbuild task when you build your project? If possible can you post your project file here?

/Q

#121891
May 20, 2015 8:31
Vote:
 

Yes, there's a lot of stuff going on. I'm guessing the file copying from /packages is done async somehow, by multipe projects with some of the same refs into the same /bin.

But since no one else is replying here I'm concluding that it's more of a project related issue than something others are seeing as well.

#121930
May 20, 2015 15:39
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.