16
votes

Sometimes when I try to start a ASP.Net application (debugging) the application will not start. Visual studio looks like the application is running, the status bar changes its color to orange. A Browser opens and is loading “forever”. IIS Express is running and the site gets displayed in the context menu of the IIS try application. I do not get any exception; the application just won’t start.

I tried to stop debugging and manually stopped IIS Express and started debugging again, but it didn’t work. The only thing which works is closing Visual Studio and open it again. Then I can start the application n times until I get the same problem again.

The application is not the problem, I never had this problem debugging the same application with Visual Studio 2013.

  • Is there a solution to this problem?
  • Do log files or something like this exist where I can find information about what is wrong?

I’m working with Visual Studio 2015 Update 1.

2
This link will help for you :) stackoverflow.com/questions/22514397/… Watch the 'Terminate all' instructionYerkon
Hi there @musium - I think we have the same error: stackoverflow.com/questions/34462634/…Lost_In_Library
Same problem, any news on this issue?Marco
@Marco Not really I still have the problem. But I found a way workaround. See my answer.musium
@musium, you can kill IIS Express also inside Visual Studio, launching debug (IIS express hangs) and clicking immediately on "Debug/Terminate All" menu command. If you exit from a debug session with the same command, all works fine on next debug session, but you loose web server while editing code. So you can exit with "Debug/Stop Debug" comamnd, IIS stay active, and the when you want to debug again you can hit F5, Terminate All, F5Marco

2 Answers

5
votes

Solution/Workaround:

I still have the same problem and I can’t find a way to solve it.
But the following script works as a workaround:

taskkill /f /im iisexpress.exe 

It kills iisexpress which seams to cause the problem.

1
votes
tasklist /fi "imagename eq iisexpress.exe" |find ":" > nul
if errorlevel 1 taskkill /f /im "iisexpress.exe"

This command will solve the first debug problem. Kills iisexpress.exe, when it's executed. Not every time.