Monday, July 30, 2012

Attach to the correct w3wp process in Visual Studio 2010

In Visual Studio 2010 on W2k8R2 or W2k3

Click Tools >> External Tools

Click Add

For SharePoint 2010 (W2k8R2 IIS 7)

Title: w3wp process

Command: %windir%\system32\inetsrv\appcmd.exe

Arguments: list wp

Select, Use Output Window

Click OK


For SharePoint 2007 (W2k3 IIS 6)

Title: w3wp process

Command: cscript.exe

Arguments: c:\windows\system32\iisapp.vbs

Select, Use Output Window

Click OK



To use:

Click Tools >> w3wp process

In the Output window, you will see the results


To Attach to the correct process:

Press ctrl + alt + p

Select the wpw3 process with the corresponding ID from the values in the Output window


Click Attach

No comments: