Debugging one website in a solution of four

I have a solution with four websites in it, when I debug the website, I get four instances of the ASP.Net deployment server, can I just debug one website and not launch the others?

+4
source share
2 answers

In the visual studio, click on the root of each website. The project properties window will appear. There calle property is "Always Start When Debugging". Just turn off websites so you don’t have to start the debugger.

+6
source

I assume that you are launching the website through a web server that is part of the visual studio (by clicking the start arrow in Visual Studio). I'm not sure if there is a way to get a visual studio to just run one of the sites, but you could do it manually through IIS. Basically, instead of using the built-in web server that comes with Visual Studio, you are going to use the IIS instance that is installed on your computer.

Go to the IIS control panel and configure the virtual directory only for the website you want to debug. Then return to Visual Studio and use the Attach to Process option on the Debug menu. You will need to connect to the IIS process, so it will either be called aspnet_wp.exe or w3wp.exe, depending on the version of IIS you installed. After you have connected to the process for debugging, you can simply open a web browser and use the address for the virtual directory that you configure, and the visual studio will stop at any breakpoints that you set in the code.

+1
source

All Articles