Solved

Problem with [solutionname].vshost.exe when debugging in Visual Studio 2005

Posted on 2007-11-23
8
1,582 Views
Last Modified: 2013-11-26
Hi all,

When I try to run a debug on a solution I'm curently developing in VB .NET 2005, I continually get the following messages (they are translated from the German as my system is in German):

1st try:  Operation could not be completed.  The process cannot access a file, as it is being used by another process."

2nd try: "Could not copy a support file, [...] [solutionname].vshost.exe." Please verify that the path exists and is writeable."

The path exists and is writeable.

If I make these two tries at debugging and then close and reopen visual studio, the problem disappears and I can debug, but as soon as I modify any code the problem reappears, and I have to restart Visual Studio.

If I do not make these two tries and close and reopen Visual Studio, restarting the program does not make the problem go away.

Anyone know what could be causing this strange behaviour?

Thanks in advance,

JaimeHy
0
Comment
Question by:jaimehy
[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
  • 3
  • 2
  • 2
  • +1
8 Comments
 
LVL 55

Expert Comment

by:Jaime Olivares
ID: 20338319
>>When I try to run a debug on a solution I'm curently developing in VB .NET 2005
What do you mean? are you trying to run debugger after an exception?
0
 

Author Comment

by:jaimehy
ID: 20338368
Many thanks for your interest Jaime,

What I mean is simply pressing F5.  The program builds successfully, but doesn't open in debug mode.  As I say, I just get the messages described above.

Best wishes,

your namesake,

JaimeHy
0
 
LVL 55

Expert Comment

by:Jaime Olivares
ID: 20338381
Maybe a corrupted file
I suggest you to create a new solution, and attach all your existing source files to it.
0
Congratulations! You’re Certified – Now What?

Starting a new career can be overwhelming. Becoming certified in your field of expertise is a great start, but where do you go from here?  Here are some tips to help you on your career journey.

 
LVL 19

Accepted Solution

by:
SteveH_UK earned 500 total points
ID: 20339357
This happens when VS doesn't release a lock on a file it creates as part of the debugging process.  The best you can do is rename the old file while VS is running, or delete it when it is not.

There is no way round it that I have found in 2005, and it happens a lot, but irregularly! :(

However, the way round that I've suggested always works.
0
 
LVL 19

Expert Comment

by:SteveH_UK
ID: 20339364
The .vshost.exe program provides the interface to Visual Studio for debugging, and is created as part of the debug execution (F5) step, and so it can be deleted any time.
0
 

Author Comment

by:jaimehy
ID: 20348894
Much obliged SteveH, this business was driving me mad.

This problem has come up more than once with me, so it's great to have a solution!

Thanks,

Jaime  
0
 
LVL 19

Expert Comment

by:SteveH_UK
ID: 20349505
No problem.  It is quite a frequent issue.
0
 

Expert Comment

by:Pizpot
ID: 20939692
It is a pain that is for sure! If I try to do both debugging and building, I get the same errors. (2008 Express)

"To disable the hosting process clear the Enable the Visual Studio hosting process checkbox in the project properties window and recompile the solution."
0

Featured Post

Want Experts Exchange at your fingertips?

With Experts Exchange’s latest app release, you can now experience our most recent features, updates, and the same community interface while on-the-go. Download our latest app release at the Android or Apple stores today!

Question has a verified solution.

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

More often than not, we developers are confronted with a need: a need to make some kind of magic happen via code. Whether it is for a client, for the boss, or for our own personal projects, the need must be satisfied. Most of the time, the Framework…
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
There are cases when e.g. an IT administrator wants to have full access and view into selected mailboxes on Exchange server, directly from his own email account in Outlook or Outlook Web Access. This proves useful when for example administrator want…
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …

626 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