为什么运行ASP.Net页面部分回发时,脚本块在VS2010调试器无休止地增长? [英] Why do script blocks grow endlessly in VS2010 Debugger when running ASP.Net page with partial postbacks?

查看:191
本文介绍了为什么运行ASP.Net页面部分回发时,脚本块在VS2010调试器无休止地增长?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在使用含有部分回发各种验证控件在UpdatePanel一个ASP.Net页,在Visual Studio 2010脚本调试器窗口开始显示这似乎是匿名的我们自动生成的脚本块条目不断增长的名单因为它被重新装入有关的控制面板上的功能。看来,从previous倍的面板进行了更新旧脚本块不设置成列表只是不断增长,减缓页和调试,直到IE被关闭,于是它可能需要很长的时间来删除数百块已经出现了。

On an ASP.Net page that uses an UpdatePanel containing various validated controls for partial postbacks, the Visual Studio 2010 script debugger window starts to show an ever growing list of "Script Block" entries which appear to be anonymous our auto-generated functions related to the controls on the panel as it is reloaded. It appears that old script blocks from previous times the panel was updated are not disposed so the list just keeps on growing, slowing down the page and the debugger, until IE is closed whereupon it can take a long time to delete the hundreds of blocks that have appeared.

这是与页面运行方式或调试器的神器有问题?比较这似乎是后者的调试和非调试页面的性能,但它是很好的了解是怎么回事,为什么。

Is this a problem with the way the page is operating or an artifact of the debugger? Comparing performance of the debugged and non-debugged page it appears to be the latter, but it would be good to know what is going on and why.

推荐答案

嘛嘛这里是你的答案。

Well Well here is your answer.

<一个href=\"http://vishaljoshi.blogspot.com/2009/06/disabling-script-debugging-with-vs-2010.html\">http://vishaljoshi.blogspot.com/2009/06/disabling-script-debugging-with-vs-2010.html

基本上当你调试通过VS2008 / 2010,IE8和转发,脚本调试将自动启用。这是由许多批评。但是很少有解决方法。

Basically when you debug through VS2008/2010, IE8 and forward, script debugging will be enabled automatically. Which is criticized by many. However there are few workarounds.

第一个是上面的文章,告诉你,使Silverlight的调试,并告诉你这两个项目的路径,以及网站,去哪里以及如何启用它。

First one is in above article which tells you to enable Silverlight debugging and tells you path for both Projects as well Websites, where to go and how to enable it.

一旦启用了Silverlight的调试JS调试截止时既不能并排。

Once you enable silverlight debugging JS debugging is turned off as both can't run side by side.

缺点(如果你真的认为这是):需要Silverlight的VS工具来安装

Drawback (if you really think it is ): Silverlight tools for VS need to installed

启动应用程序没有调试(CTRL + F5)一旦应用程序运行通过点击调试 - >附加到进程手动附加调试器。

Start the application without debugging (CTRL + F5) once app running attach debugger manually by clicking on Debug->Attach to Process.

有关VS 2008中也有像编辑注册表项等几种选择。

For VS 2008 there are several alternatives like editing registry keys and so forth.

如果有人需要VS 2008年关于该检查了这一点帮助。
<一href=\"http://blogs.msdn.com/b/greggm/archive/2009/04/06/disabling-script-debugging-in-vs-2008-ie8.aspx\">http://blogs.msdn.com/b/greggm/archive/2009/04/06/disabling-script-debugging-in-vs-2008-ie8.aspx

If anyone need VS 2008 help regarding that check this out. http://blogs.msdn.com/b/greggm/archive/2009/04/06/disabling-script-debugging-in-vs-2008-ie8.aspx

这篇关于为什么运行ASP.Net页面部分回发时,脚本块在VS2010调试器无休止地增长?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆