在documentcompleted事件之前禁止从webbrowser控件加载图像

时间:2010-01-12 11:13:01

标签: c# .net webbrowser-control

我想阻止页面中的图片加载到WebBrowser控件中。我希望它在DocumentCompleted事件发生之前发生。有没有办法做到这一点?

2 个答案:

答案 0 :(得分:8)

试试这段代码:

RegistryKey RegKey = Registry.CurrentUser.OpenSubKey(@"Software\Microsoft\Internet Explorer\Main", true);
RegKey.SetValue("Display Inline Images", "no");

它更改了注册表项。

答案 1 :(得分:1)

相关问题