Solved

MSB3061: Unable to delete file "bin\Debug\<<DLLName>>". Access to the path '<<ReferencePNE>>' is denied

Posted on 2013-11-13
2
3,008 Views
Last Modified: 2013-11-14
Hi,

I'm having problems compiling my project in Visual Studio 2010.
After I compile the first time (after startup), I can't compile a second time because all the DLLs reference appears to be locked. I am not using any source control.
My project is very simple project.

Below is my build output.

 
------ Clean started: Project: WEHinters, Configuration: Release Any CPU ------
c:\WINNT\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(3607,9): warning MSB3061: Unable to delete file "f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\WEHinters.dll". Access to the path 'f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\WEHinters.dll' is denied.
c:\WINNT\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(3607,9): warning MSB3061: Unable to delete file "f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\WEHinters.pdb". Access to the path 'f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\WEHinters.pdb' is denied.
c:\WINNT\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(3607,9): warning MSB3061: Unable to delete file "f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\GSL.Remote.dll". Access to the path 'f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\GSL.Remote.dll' is denied.
c:\WINNT\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(3607,9): warning MSB3061: Unable to delete file "f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\GSL.Remote.Framework.dll". Access to the path 'f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\GSL.Remote.Framework.dll' is denied.
c:\WINNT\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(3607,9): warning MSB3061: Unable to delete file "f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\GSL.Shared.Configuration.dll". Access to the path 'f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\GSL.Shared.Configuration.dll' is denied.
c:\WINNT\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(3607,9): warning MSB3061: Unable to delete file "f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\GSL.Shared.dll". Access to the path 'f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\GSL.Shared.dll' is denied.
c:\WINNT\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(3607,9): warning MSB3061: Unable to delete file "f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\GSL.Shared.Exceptions.dll". Access to the path 'f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\GSL.Shared.Exceptions.dll' is denied.
c:\WINNT\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(3607,9): warning MSB3061: Unable to delete file "f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\GSL.Shared.Framework.dll". Access to the path 'f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\GSL.Shared.Framework.dll' is denied.
c:\WINNT\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(3607,9): warning MSB3061: Unable to delete file "f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\GSL.Shared.Utils.dll". Access to the path 'f:\visual studio 2010\Projects\WEHinter\WEHinter\bin\Release\GSL.Shared.Utils.dll' is denied.
========== Clean: 1 succeeded, 0 failed, 0 skipped ==========
0
Comment
Question by:GouthamAnand
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 44

Accepted Solution

by:
AndyAinscow earned 500 total points
ID: 39647299
A couple of points that might result in this error.
There are two copies of visual studio running with the same project open in each.
The exe is actually running outside of visual studio when you attempt the second build - so using the dll's which prevents them being deleted.
0
 

Author Closing Comment

by:GouthamAnand
ID: 39648018
Thanks a lot.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This document covers how to connect to SQL Server and browse its contents.  It is meant for those new to Visual Studio and/or working with Microsoft SQL Server.  It is not a guide to building SQL Server database connections in your code.  This is mo…
Wouldn’t it be nice if you could test whether an element is contained in an array by using a Contains method just like the one available on List objects? Wouldn’t it be good if you could write code like this? (CODE) In .NET 3.5, this is possible…
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an antispam), the admini…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question