Vistual Studio 2008 SP1 调试不适用于 IIS 进程(有时)
我在 Windows 7 上使用 VS 2008 SP1,并尝试通过将调试器附加到 w3wp 进程来调试 ASP.net 网站项目,我注意到调试器每次都不会在断点处停止。我对此问题进行了大量研究,发现它是一个已知问题,请参阅此链接:http://support.microsoft .com/kb/957912。我尝试了修补程序,但仍然面临同样的问题,测试真的很烦人。有人遇到过这个问题吗?
注意:我使用的是 .net 3.5 SP1 中引入的 Asp.net 路由功能。
I am using VS 2008 SP1 on Windows 7 and tyring to debug a ASP.net website project by attaching debugger to w3wp process, I noticed that debugger wont stop at the breakpoint at everytime. I researched a lot on this issue and found that its a known issue see this link: http://support.microsoft.com/kb/957912. I tried hotfix but still I am facing the same issue, its really annoying to test. Anyone had this issue?
Note: I am using Asp.net routing feature which introduced in .net 3.5 SP1.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
检查您是否在“附加到”对话框中选择了“托管代码”。
并且,为了以防万一,也许这是您的路由问题并且与调试器无关?
Check that you select "Managed code" in "attach to" dialog.
And, just in case, maybe it's a problem with your routing and there is nothing to do with debugger?
您必须以管理员身份运行 Visual Studio,否则您将无法将调试器附加到其他进程。
或者你有时会在发布模式下编译吗?您还必须在配置文件中设置选项 debug='true' (这取决于您设置断点的位置),并在附加调试器(附加到托管代码)时设置正确的模式。
当您不运行最新版本的代码时,也不会命中断点。确保在附加到 w3wp.exe 之前重建代码。在调试模式下使用 F5 启动代码应该始终有效。
You have to run Visual Studio as an administrator otherwise you are not allowed to attach the debugger to another process.
Or do you sometimes compile in release mode? You also have to set the option debug='true' in the configuration file (it depends on where you set the breakpoint) and set the correct mode when attaching the debugger (attach to managed code).
The breakpoint is also not hit, when you not run the latest version of the code. Make sure you rebuild the code before you attach to w3wp.exe. Start the code with F5 in debug mode should always work.