Keyboard shortcut to attach to w3wp.exe in VS11

后端 未结 6 616
渐次进展
渐次进展 2021-01-30 07:19

Since VS11 removed macros, I can no longer fire this macro to attach to the webserver using a keyboard shortcut.

Is there another way to start the debugger and attach to

6条回答
  •  说谎
    说谎 (楼主)
    2021-01-30 07:21

    The debugger in visual studio automatically attaches to the web server if you check that box in the project properties. A macro has never been necessary for that.

    Check the "Use Local IIS Web server" box in Visual Studio, on the "Web" tab of your project properties. Then check the "ASP.NET" box at the bottom, under "Debuggers"

    To debug, just hit F5.

    EDIT

    To get F5 to simply attach to w3wp.exe...

    Make sure you have a web project set as the StartUp project enter image description here

    On that web project's settings Web tab, just select "Use Local IIS Web server" and put in the url you use to go to your site (the url really only matters if you keep the Start Action on "Current Page"). I don't like having a browser get launched, because there's a good chance I'm actually on another site in the project. But what's great is once it attaches to w3wp.exe, it'll be debugging any site. enter image description here

提交回复
热议问题