Results 1 to 5 of 5

Thread: [RESOLVED] Compiler cannot copy the .exe file from obj\x86\Debug folder to \bin folder

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Mar 2013
    Location
    San Francisco, CA
    Posts
    528

    Resolved [RESOLVED] Compiler cannot copy the .exe file from obj\x86\Debug folder to \bin folder

    When I compile my project, I get the following error:

    Code:
    Could not copy "obj\x86\Debug\Vehicle Tracker.exe" to "bin\Debug\Vehicle Tracker.exe". Beginning retry 1 in 1000ms. The process cannot access the file 'bin\Debug\Vehicle Tracker.exe' because it is being used by another process.
    The compiler makes 10 attempts to copy the .exe file from the obj\x86\Debug folder to the bin\Debug folder, then stops the compilation process.

    The way I work around this error is to do the following:
    1. Close VS2010.
    2. Delete the project's \bin folder.
    3. Restart VS2010.
    4. Compile the project.

    There must be a better way. Can someone please help me resolve this error?

    Thanks.
    Attached Images Attached Images  

  2. #2

    Thread Starter
    Fanatic Member
    Join Date
    Mar 2013
    Location
    San Francisco, CA
    Posts
    528

    Re: Compiler cannot copy the .exe file from obj\x86\Debug folder to \bin folder

    I have tried 2 approaches to fix this issue. First, I tried to repair my VS2010 installation. After completing the repair and restarting my computer the problem copying the .exe file to the bin\Debug folder still exists. Next, I uninstalled VS2010 and deleted the "D:\Program Files (x86)\Microsoft Visual Studio 10.0" folder. Then I reinstalled VS2010 via the original CD-ROM media (from Microsoft). After restarting my computer the problem copying the .exe file to the bin\Debug folder is gone.

    So I'm going to mark this thread "Resolved".

  3. #3
    PowerPoster techgnome's Avatar
    Join Date
    May 2002
    Posts
    34,687

    Re: [RESOLVED] Compiler cannot copy the .exe file from obj\x86\Debug folder to \bin f

    It'll happen again... when it does, try this instead:
    1) right-click the solution in the solution explorer, select Clean Solution...

    now rebuild.

    Done.

    What happens sometimes, no one seems to know when or why, the file becomes locked, and when it does, it's usually a simple matter of deleting the bin & obj folders, which is what hte clean process does. If that doesn't work, or it too errors out, simply close VB, delete the folders by hand. Either way, that should solve the issue w/o re-installing VS.

    -tg
    * I don't respond to private (PM) requests for help. It's not conducive to the general learning of others.*
    * I also don't respond to friend requests. Save a few bits and don't bother. I'll just end up rejecting anyways.*
    * How to get EFFECTIVE help: The Hitchhiker's Guide to Getting Help at VBF - Removing eels from your hovercraft *
    * How to Use Parameters * Create Disconnected ADO Recordset Clones * Set your VB6 ActiveX Compatibility * Get rid of those pesky VB Line Numbers * I swear I saved my data, where'd it run off to??? *

  4. #4

    Thread Starter
    Fanatic Member
    Join Date
    Mar 2013
    Location
    San Francisco, CA
    Posts
    528

    Re: [RESOLVED] Compiler cannot copy the .exe file from obj\x86\Debug folder to \bin f

    You're right, the error is back .

    right-click the solution in the solution explorer, select Clean Solution...
    Can't see the "solution" in the Solution Explorer...

    Name:  3-15-2016 3-10-29 PM.png
Views: 1993
Size:  61.7 KB

    My project is named "Vehicle Tracker" and that is the first row of the Solution Explorer. When I right-click it, there is a "Clean" item in the pop-up context menu. Clicking this item does not delete the bin and obj folders.

    So I'm assuming that the "solution" is the project name, if not then what am I missing?
    Last edited by Mark@SF; Mar 15th, 2016 at 05:17 PM.

  5. #5
    Super Moderator FunkyDexter's Avatar
    Join Date
    Apr 2005
    Location
    An obscure body in the SK system. The inhabitants call it Earth
    Posts
    7,957

    Re: [RESOLVED] Compiler cannot copy the .exe file from obj\x86\Debug folder to \bin f

    That's because it's a single project solution. In this case just right click on the project and clean that.
    The best argument against democracy is a five minute conversation with the average voter - Winston Churchill

    Hadoop actually sounds more like the way they greet each other in Yorkshire - Inferrd

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width