简体   繁体   English

自动附加到Visual Studio中的进程

[英]Automatically attach to process in Visual Studio

I have searched this site, and numerous others, looking for a solution to this problem. 我搜索了该站点以及其他众多站点,以寻找解决此问题的方法。 When I press F5 to start debugging my web app it will launch the default browser (IE in this case) with the web site. 当我按F5键开始调试我的Web应用程序时,它将启动该网站的默认浏览器(在本例中为IE)。 But if I want to debug the code I must goto Tools > Attach To Process. 但是,如果要调试代码,则必须转到工具>附加到进程。

In my previous job I was able to press F5 and the debugger would automatically start and I could step through the code, but I can't seem to do that here. 在上一份工作中,我可以按F5键,调试器将自动启动,并且可以逐步执行代码,但是我似乎无法在此处完成。 To add to matters, there is someone else in the office whose also works as I would hope but he says he didn't do anything and doesn't know how to sort it. 更麻烦的是,办公室里还有其他人也可以按我希望的那样工作,但他说他什么也没做,也不知道如何分类。

I have tried numerous things, like adding debug="true" in the web.config but to no avail. 我尝试了很多事情,例如在web.config中添加debug="true" ,但无济于事。

There must be a definitive way of achieving this, without having to resort to macros and the like. 必须有一种确定的方法来实现此目标,而不必诉诸宏等。

I think it's not related to the button itself but could be the preferences you chose on startup. 我认为它与按钮本身无关,而可能是您在启动时选择的首选项。 Go to Debug > Start Debugging on the menu. 转到菜单上的调试>开始调试。 What button appears on the right of the menu? 菜单右侧显示什么按钮?

HTH. HTH。

Ok I figured out a workaround to get it to work...Don't know why this occurs, maybe someone will be able to enlighten me. 好的,我想出了一个解决方法,以使其正常工作...不知道为什么会发生这种情况,也许有人可以启发我。

But I closed all other Visual Studio solutions I had open and now it debugs properly. 但是我关闭了我打开的所有其他Visual Studio解决方案,现在可以正确调试了。 It was actually a colleague who put me onto this as he was in a similar scenario and just tried a lot of different things. 实际上是一位同事,就像他在类似情况下一样,我尝试了很多不同的事情。

Any idea why this would be happening? 知道为什么会这样吗?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Visual Studio附加到进程不起作用 - visual studio attach to process not working Visual Studio 2010附加到进程失败 - Visual Studio 2010 attach to process fails 附加到进程在Windows 7中的Visual Studio 2008中不起作用 - Attach to Process is not working in Visual studio 2008 in Windows 7 Visual Studio必须附加哪个进程来运行DNX进程? - Which process Visual Studio has to attach to run DNX process? Visual Studio加载项自动附加到Development Server - Visual Studio Add-In To Automatically Attach to Development Server 在Visual Studio 2012 Express for Web中找不到“附加到进程”选项 - Cannot find “Attach to Process” option in Visual Studio 2012 Express for Web Visual Studio 2012:无法附加进程。 已附加调试器 - Visual Studio 2012: Unable to attach the process. A debugger is already attached 如何在Visual Studio的“附加到进程”对话框中获取w3wp.exe进程? - How do I get w3wp.exe process available in the 'Attach to Process' dialogue in Visual Studio? Visual Studio 2010 Web Developer Express Tools.Attach to Process不存在 - Visual Studio 2010 Web Developer Express Tools.Attach to Process is not exists 如何避免在Windows XP的Visual Studio 2008中不必要地使用“附加到进程”? - How to avoid the unwanted use of “Attach to the process ” in Visual Studio 2008 in Windows XP?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM