Home Dashboard Directory Help
Search

[Application].vshost.exe does not close properly by nramsey34


Status: 

Closed
 as Not Reproducible Help for as Not Reproducible


5
0
Sign in
to vote
Type: Bug
ID: 358562
Opened: 7/29/2008 12:03:58 PM
Access Restriction: Public
0
Workaround(s)
view
2
User(s) can reproduce this bug

Description

I am trying to create my first C# program in Visual Studio 2008. Each time I open Visual Studio I am able to build & debug once with no problems. On the second attempt to rebuild and debug the project results in the following error: "The operation could not be completed. The process could not access the file because it is being used by another process." The occurs each time you attempt to rebuild and debug (i.e. after a change is made.) After the second time, if I do not make any changes and then try to debug (not rebuilding), I get the following error: Visual Studio could not copy a support file to the following location: ...\Projects\[ProjectName]\[SolutionName]\bin\debug\[ProjectName].vshost.exe'. Please verify the location exists and is writable."

If you close Visual Studio and then re-open it, you are again allowed to build and debug once.
Details
Sign in to post a comment.
Posted by David Scherf on 4/18/2011 at 5:02 AM
This problem has started to occur in VS 2010 SP1, is bugging me no end
Posted by Dave Waterworth on 11/16/2009 at 7:40 PM
I get the same behaviour, but with VS2008. Every time I run a specific project from a network drive, the vshost.exe fails to close (operation could not complete).
Posted by F.OGUER on 8/7/2009 at 1:33 AM
I have the same issue with VS2005 when my source files on a network drive.
Posted by Microsoft on 10/28/2008 at 4:50 PM
Thank you for the claification, we will certianly investigate the issue and see how we can improve this in future release of Visual Studio.

Best Regards,
Visual Studio Debugger Team
Posted by nramsey34 on 9/12/2008 at 6:01 AM
I think I may have some clarification on this issue. I originally had my source files on a network drive. Moving them to the local HDD seems to have corrected this problem. I feel like you should be able to run code from a network drive, but that may help you to replicated the error. It will work as a solution for me for now.
Posted by Microsoft on 9/10/2008 at 7:32 PM
Unfortunately, we are still not able to reproduce this issue in our labs. One additional thing to try would be to turn off the hosting process. You can do this by following these steps:
1) In the Project menu, select "[project name] Properties"
2) Click on Debug
3) Uncheck the box that says "Enable the Visual Studio hosting process"

Thanks,
Visual Studio Debugger Team
Posted by nramsey34 on 8/20/2008 at 7:02 AM
The vshost process starts to run whenever I load the solution in VS and stops whenever I close VS. I tried it a couple of different times and did not see any other vshost processes.
Posted by Microsoft on 8/19/2008 at 4:34 PM
After you exit your application, take a look at task manager or process explorer. Are there any orphaned vshost processes running?

Thanks,
Visual Studio Debugger Team
Posted by Microsoft on 8/11/2008 at 10:38 PM
Thanks for your response. We are escalating this bug to the product unit who works on that specific feature area. The team will review this issue and make a decision on whether they will fix it or not for the next release.

Thank you,
Visual Studio Product Team
Posted by nramsey34 on 7/31/2008 at 11:29 AM
Also, as I progess in the project, this problem seems to be getting worse. Initially I was able to close and reopen VS and the debug process would work. Now I have to close it 2 or 3 times. Also, unlike what I reported before - the first build of the project now results in the same error.
Posted by nramsey34 on 7/30/2008 at 5:32 AM
Thank you for the quick response. I believe that the issue is that the file is staying locked. However, I cannot imagine what I would be doing to lock it. The problem occurs if I exit the program through an Application.Exit() call or if I stop the debugging process with the stop button. I am not manually altering the file in any way.
Posted by Microsoft on 7/29/2008 at 6:07 PM
Hi

Thanks for your feedback. Based on your case, could you please go to the following post and make sure you didn't lock the file.
http://blogs.msdn.com/dtemp/archive/2004/08/17/215764.aspx
If you still have this error occurring, please provide us with log files as specified in the post below:
http://blogs.msdn.com/heaths/archive/2008/05/09/visual-studio-and-net-log-collection-utility.aspx
We will re-investigate.

Thanks,
Kylin
Sign in to post a workaround.