Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Attach Debugger to IIS instance

I have IIS 5.1 on a XP machine, and visual studio 2005. How do I go about attaching my debugger to IIS instance.

BTW: I'm not seeing the IIS process within the running processes or probably I don't know what to look for .

like image 915
Mihai Lazar Avatar asked May 11 '09 16:05

Mihai Lazar


2 Answers

In Visual Studio:

  1. Click "Debug" from the menu bar
  2. Click "Attach to Process"
  3. Check the "Show processes from all users" checkbox in the bottom left corner
  4. Select aspnet_wp.exe, w3p.exe, or w3wp.exe from the process list
  5. Click "Attach"
like image 176
Al W Avatar answered Oct 19 '22 04:10

Al W


Just to clarify Jimmie R. Houts answer…

If you want to debug the web application VS and IIS you can do the following:

  1. Host the site inside IIS (virtual directory etc).
  2. Then in VS2005 do this:

    • Right Click on Web Project → Properties → Start options → Use Custom Server → Base URL → Enter Site Address as Hosted in IIS.
    • Hit F5 and you will be able to Debug your code

Same works for VS 2008 also.

like image 42
Amitd Avatar answered Oct 19 '22 02:10

Amitd