Debugging CS 2.0 in VS 2005
While playing with CS 2.0 and WF in VS 2005 I found that most people were debugging by attaching to the aspnet_wp process. Although this works well, it's more convenient to debug with F5, so I started poking around.
Here are the steps I followed, but bear in mind that these haven't been approved by ScottW - so making these changes may have unintended consequences.
- Get the CS 2.0 SDK source
- Open the src/Web/CommunityServerWeb20.csproj file in notepad
- Follow Step 6 of Scott Guthrie's article, specifically to delete the <ProjectType> line and add the following line:
<ProjectTypeGuids>{349c5851-65df-11da-9384-00065b846f21};{fae04ec0-301f-11d3-bf4b-00c04f79efbc}</ProjectTypeGuids>
- Install the latest WAP download (I installed the latest GDR build and the WAP build from internal MSFT servers, but hopefully the public version works as well)
- On opening VS 2005 and the CS solution you should see that the Web project has a Web property page now.
- I had to choose the IIS web server option (I had setup localhost/wwf for my CS installation) because the VS Dev Server keeps throwing the exception: “Type is not resolved for member 'Microsoft.ScalableHosting.Security.RolePrincipal,MemberRole”
Now I can set breakpoints, hit F5 and they will break without having to attach to aspnet_wp.