Winform.WebBrowser控件在调试器中抛出许多异常导致性能不佳 [英] Winform.WebBrowser control throws numerous exceptions in debugger causing poor performance

查看:124
本文介绍了Winform.WebBrowser控件在调试器中抛出许多异常导致性能不佳的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用Win32桌面应用程序中托管的Winform WebBrowser组件。 这工作正常,但在调试器中运行时会出现如下所示的异常流异常:

I'm using a Winform WebBrowser component hosted in a Win32 desktop application.  This works fine, but when running in a debugger there is a constant stream of exceptions like this reported:

MapChart.exe中的0x749DA832抛出异常:Microsoft C ++异常:Js :: JavascriptExceptionObject at内存位置0x005FD980。
$
MapChart.exe中的0x749DA832抛出异常:Microsoft C ++异常:内存位置为0x005FD36C的Js :: JavascriptExceptionObject。

MapChart.exe中的0x749DA832抛出异常:Microsoft C ++异常:Js :: JavascriptException对象在内存位置0x005FD470。
$
在MapChart.exe中的0x749DA832处抛出异常:Microsoft C ++异常:[rethrow]在内存位置0x00000000。

MapChart.exe中0x749DA832处抛出异常:Microsoft C ++异常:内存位置为0x005FD980的Js :: JavascriptException对。

MapChart.exe中0x749DA832抛出异常:Microsoft C ++异常:内存中的Js :: JavascriptExceptionObject location 0x005FD36C。
$
M中的0x749DA832抛出异常apChart.exe:Microsoft C ++异常:Js :: JavascriptException对象在内存位置0x005FD470。
$
在MapChart.exe中的0x749DA832处抛出异常:Microsoft C ++异常:[rethrow]在内存位置0x00000000。

MapChart.exe中的0x749DA832抛出异常:Microsoft C ++异常:内存位置为0x005FD980的Js :: JavascriptException对。

MapChart.exe中0x749DA832抛出异常:Microsoft C ++异常:Js ::内存位置为0x005FD67C的JavascriptExceptionObject。
$
MapChart.exe中的0x749DA832抛出异常:Microsoft C ++异常:内存位置为0x005FD780的Js :: JavascriptExceptionObject。

MapChart中的0x749DA832抛出异常.exe:Microsoft C ++异常:[rethrow]在内存位置0x00000000。

Exception thrown at 0x749DA832 in MapChart.exe: Microsoft C++ exception: Js::JavascriptExceptionObject at memory location 0x005FD980.
Exception thrown at 0x749DA832 in MapChart.exe: Microsoft C++ exception: Js::JavascriptExceptionObject at memory location 0x005FD36C.
Exception thrown at 0x749DA832 in MapChart.exe: Microsoft C++ exception: Js::JavascriptExceptionObject at memory location 0x005FD470.
Exception thrown at 0x749DA832 in MapChart.exe: Microsoft C++ exception: [rethrow] at memory location 0x00000000.
Exception thrown at 0x749DA832 in MapChart.exe: Microsoft C++ exception: Js::JavascriptExceptionObject at memory location 0x005FD980.
Exception thrown at 0x749DA832 in MapChart.exe: Microsoft C++ exception: Js::JavascriptExceptionObject at memory location 0x005FD36C.
Exception thrown at 0x749DA832 in MapChart.exe: Microsoft C++ exception: Js::JavascriptExceptionObject at memory location 0x005FD470.
Exception thrown at 0x749DA832 in MapChart.exe: Microsoft C++ exception: [rethrow] at memory location 0x00000000.
Exception thrown at 0x749DA832 in MapChart.exe: Microsoft C++ exception: Js::JavascriptExceptionObject at memory location 0x005FD980.
Exception thrown at 0x749DA832 in MapChart.exe: Microsoft C++ exception: Js::JavascriptExceptionObject at memory location 0x005FD67C.
Exception thrown at 0x749DA832 in MapChart.exe: Microsoft C++ exception: Js::JavascriptExceptionObject at memory location 0x005FD780.
Exception thrown at 0x749DA832 in MapChart.exe: Microsoft C++ exception: [rethrow] at memory location 0x00000000.

(重复100次)

我已将调试器配置为抛出异常时不会停止,但它仍然显然会注意到它们并将它们列出到输出窗口。 这似乎会极大地影响性能: 当我在浏览器之外运行可执行文件时,它比调试器下运行
要快得多。 不在输出窗口中列出异常对性能没有影响。

I've configured the debugger to not stop when exceptions are thrown, but it still apparently notices them and lists them to the output window.  This appears to greatly impact performance:  when I run the executable outside of the browser, it runs much more quickly than under the debugger.  Not listing exceptions in the output window has no impact on performance.

有没有办法让调试器忽略这些异常以在调试时提供更好的性能?

Is there any way to get the debugger to ignore these exceptions to give better performance while debugging?

推荐答案

您好Anonymous12731,

Hi Anonymous12731,

如果您不想列出输出窗口中的异常消息,一个想法是你可以在TOOLS-> Options-> Debugging-> Output windows下禁用它。

If you don't want to list the exception messages in the output windows, one idea is that you could disable it under TOOLS->Options->Debugging->Output windows.

由于只是特定的应用程序有此问题,我的建议是你最好抛出异常,并真正分析它的原因。

Since just the specific app has this issue, my suggestion is that you'd better to throw the exception, and really analyze the reason of it.

最好的问候,

杰克


这篇关于Winform.WebBrowser控件在调试器中抛出许多异常导致性能不佳的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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