我正在使用 C# WebBrowser,有时在加载页面时(并非总是)我会收到以下提示:
An error has occured in the script on this page.
Line 1
Char 45774
Error Object required
Code 0
URL http://xxx.i_replaced_the_link_here.com/blah_BLAH_blah123
Do you want to continue running scripts on this page?
Yes / No
我想继续,但我不能一直点击"is"按钮。
你认为我该如何解决?
最佳答案
您可以将 WebBrowser.ScriptErrorsSuppressed
控件属性设置为 true
。这样你就不会收到任何错误。
关于C# WebBrowser - 如何摆脱 JavaScript 错误提示?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8009575/