Solved

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

Posted on 2013-11-13
2
2,749 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
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

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

Flash (http://en.wikipedia.org/wiki/Adobe_Flash) has evolved over the years to where it has become a masterful tool for displaying content screen.  It has excellent layout placement, UI precision as well as rendering capabilities. This, along with t…
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 this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

760 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

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now