ASP.NET 调试问题

发布于 2024-10-17 21:07:32 字数 342 浏览 7 评论 0原文

我正在 Visual Studio 2010 中构建网站。 我最近升级到了运行 Windows 7 64 位的新开发机器。 现在,当我对网页进行更改时,我必须停止调试,终止 cassini,然后在新代码生效之前再次开始调试。我在XP下没有这个问题。

我尝试过的事情...

  • 配置文件中的编译debug =“true”
  • 选项->调试->编辑并继续已启用

我不确定这是否在动态编译或编辑和继续 - 任何帮助将不胜感激。

编辑

我的一位同事没有遇到这个问题。他与我有相同的设置,使用相同的项目,相同的构建配置(任何 CPU)

I'm building web sites in Visual Studio 2010.
I recently upgraded to a new dev machine running windows 7 64-bit.
Now, when I make a change to a webpage, I have to stop debugging, kill cassini, and start debugging again before the new code takes effect. I didn't have this problem in XP.

Things I've tried...

  • compilation debug="true" in config file
  • options->Debugging->Edit and Continue is enabled

I'm not sure if this follows under dynamic compilation or Edit and Continue - any help would be appreciated.

EDIT

One of my colleagues is not having this problem. He has an identical setup to me, using the same project, same build configuration (Any CPU)

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

音盲 2024-10-24 21:07:32

原因是由于从 32 位操作系统更改为 64 位操作系统。在应用程序运行时更改代码的能力是 32 位代码所独有的。在 64 位可执行文件中,此功能被删除。

这称为“编辑并继续”。请参阅此问题,了解为什么这不适用于 64 位可执行文件:

为什么“编辑并继续”在 x64 CLR 上不起作用?

编辑: 澄清:

这不是操作系统的问题,而是构建的问题你的代码。如果您将构建配置设置为“任何 CPU”,它将在您的计算机架构下运行(在您的情况下为 x64)。您应该能够将其强制为 x86,并能够使用“编辑并继续”。

The reason is due to the change from a 32 bit os to a 64 bit os. The ability to change code while the application is running is unique to 32 bit code. In a 64 bit executable, this capability is removed.

This is known as "Edit and Continue". See this question for a good explanation of why this won't work on a 64bit executable:

Why doesn't Edit and Continue work on the x64 CLR?

EDIT: Clarification:

This isn't an issue with the OS, but rather the build of your code. If you have your build configuration set to "Any CPU", it will run under the architecture of your machine (x64 in your case). You should be able to force this to x86 and be able to use Edit and Continue.

如此安好 2024-10-24 21:07:32

64 位应用程序无法在调试期间动态修改。为了能够做到这一点,您需要更改构建目标“x86”。简单的!

只需将其改回来(如果您确实需要 64 位程序集)。

64-bit apps can't be dynamically modified during debugging. To be able to do that you'll need to change your your build target 'x86'. Easy!

Just change it back (if you really need 64-bit assemblies).

彩扇题诗 2024-10-24 21:07:32

事实证明,这是我的错...我经历过可怕的“网络 BIOS 命令限制已达到”问题。我发现一篇文章建议进行注册表编辑“HKLM\Software\Microsoft\ASP.NET\FCNMode = 1”,这基本上会关闭文件更改通知。将此值更改为 2,并应用知识库 810886 中建议的更改解决了这两个问题。

As it turns out, this was my fault... I had experienced the dreaded "network BIOS command limit has been reached" issue. I found a post that recommended doing a regedit hack "HKLM\Software\Microsoft\ASP.NET\FCNMode = 1", well this basically turns off File Change Notifications. Changing this value to 2, and applying the changes recommended in knowledge base 810886 fixed both problems.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文