Visual Studio 2010 and IIS Express lock up on build - visual-studio-2010

I have about four web projects that I am hosting in IIS Express. Whenever I do a build in Visual Studio 2010, the build will be blocked until I manually kill IIS Express. The build then completes. A new instance of IIS Express is created that works as expected.
I tried to do a prebuild event to kill IIS Express with taskkill, but the lock up seems to happen before the prebuild event is executed :/
If I stop the hosted sites, Visual Studio 2010 will also build as normal.
From research, one possibility is IIS Express is trying to display a dialog that Visual Studio 2010 is waiting for the user to interact with, but doesn't actually display the dialog.
Has anyone else had an issue with IIS Express and Visual Studio 2010 locking up on building? Or some insight on how to debug this issue?

If i remember correct the last service pack for vs 2010 corrected that error (at least on my maschine).

Sounds like visual studio is trying to do something on port 80, which IIS is blocking ( thats the default listener port for it ).
A simple google search of port 80 visual studio brings up several promising hits ( how to configure it, and hey! 2nd one even has a fix for a similar problem. )

This happens to me constantly, but then again I'm using WinXP / VS2010 / IIS Express 7.5. I suspect the WinXP part is the culprit, perhaps a bug for this particular scenario? At any rate, VS2010 wants to rebuild one of my web apps, but appears to wait indefinitely on some files in the Temporary ASP.net directory for the web app, until I stop IIS Express.

Related

Debugging Web Projects in Visual Studio 2013

I have some web projects that run fine in the debugger in VS 2012. But when I try to run the same projects in VS 2013 i run into some problems.
First the whole Devenv.exe crashed when pressing F5.
I found an article about this problem here
It suggests set ISS Express in Visual Studio to 64 bit.
That solved the problem of the whole IDE crashing.
However, with that configuration Visual Studio tries to start "Remote Debugging". Probably because Visual Studio itself is 32 bit, so it must use some "remote" techniques to debug something 64 bit. At least that's my guess on what is happening.
Remote debugging is not succeeding either. I get "Remote Debugger has stopped Working" sometimes. Sometime at the beginning of the degugging session, and sometime at the end of the session. I found an article about this problem too. It suggest to set the web project to x86 to avoid remote debugging. But that will not work in this case. It has to run 64 bit to work with IIS in 64 bit.
Error message is
Remote Debugger has stopped Working
Then
The debugger's worker process (msvsmon.exe) unexpectedly exited. Debugging will be aborted.
Anyone else seen this?
Is this a common problem in Visual Studio 2013?
EDIT: more details about the environment
I have a solution containing several projects, including two web projects.
The issue happens when I try to run any of the web projects in debugger (by pressing F5).
They are normal web projects, and I am not running anything remote.
Visual Studio itself came up with the idea of using "Remote Debugger" when I checked the "Use the 64 bit version of IIS Express for web sites and projects".
The solution was first created on a Windows 7 machine running Visual Studio 2012 and it worked well there.
When I tried to open the same solution on a new machine running Windows 8.1 and Visual Studio 2013 the problem started.
A colleague is also running the same solution on his Windows 8.1. We share the solution using a git repository.
He has both VS 2102 and VS 2013 installed. He experiences the same problems in VS 2013, so he has started to use VS 2012 for this solution.
It runs fine in VS 2012. It is the same solution and same machine as it fails in VS 2013.

Block development server window

Is there any way to avoid the window of development server? (Not stopping or avoiding to run the development server, just the window).
In Visual Studio 2010 (and before) it only appears when the development server was started. Now, in Visual Studio 2012 it is opened each time the project start, no matter if the development server has already started and you have closed it.
I've found that I can run projects using IIS Express. Also it will make our lives easier when we want to be able to access to the project running from other PC.
With Visual Studio 2012 it comes already installed (in fact is the default setting for projects started in it). With Visual Studio 2010 it can be installed (see post).

visual studio: attach debugger without starting web debugging

I have a visual studio solution with a half dozen web application projects. I often want to attach the debugger to a process. When I do this, visual studio always wants to start up cassini or IIS express or do something to run the web applications in the solution. Is there a way I can skip that, so when attaching to a process visual studio does not try to start the web applications in the current solution?
On the project properties, there's a setting called "Development Server" -> "Always Start When Debugging." Might be worth a shot.

Error when trying to deploy SharePoint 2010 solution package - SharePoint 2010 - Visual Studio 2010

After several deployments, I receive the following error when trying to re-deploy a solution:
Error occurred in deployment step
‘Recycle IIS Application Pool’: The
communication object,
System.ServiceModel.InstanceContext,
cannot be used for communication
because it has been Aborted.
The only solution I have found (not ideal) is to restart Visual Studio.
Anyone know a better way?
I have seen this a couple of times as well and the only resolution I found was to restart Visual Studio as well.
How come restarting Visual Studio will fix anything :)
You need to run Visual Studio as Administrator (by right clicking on its icon)
If still persists, restart the server.
If still persists, add the administrator account under which you are running Visual Studio to Sharepoint Central Administration for that sharepoint web portal.

Keep Project Running on IIS Express when i exit visual studio

Im Trying IIS Express out and cant figure out if its possible to keep the Project Running on the IIS Express server when i exit visual studio 2010.
Is this possible?
On Visual Studio exit, it stops all the IIS Express processes it started. Probably you should start the site you are interested in from command line after VS exit(use /site switch). Following URL may help http://learn.iis.net/page.aspx/870/running-iis-express-from-the-command-line/

Resources