dWebBrowser常用知识点

WebBrowser控件配置与使用技巧
本文介绍了如何设置WebBrowser控件以在不同的IE模式下工作,包括更改注册表键值来指定所需的IE版本模式。此外,还提供了屏蔽WebBrowser控件中弹出的脚本错误对话框的方法。

1.webbrowser调用的就是本机IE,并且webbrowser默认就是运行在IE7 mode下,除非你改变它.

2.不装IE,无法用webbrowser.

3.设置WebBrowser在IE9 mode下工作呢

There are two different sets of keys for 32 bit and 64 bit applications.

32 bit:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\MAIN\FeatureControl\FEATURE_BROWSER_EMULATION

Value Key: yourapplication.exe

64 bit:

HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Internet Explorer\MAIN\FeatureControl\FEATURE_BROWSER_EMULATION

Value Key: yourapplication.exe

The value to set this key to is (taken from MSDN here) as decimal values:

9999 (0x270F) 
Internet Explorer 9. Webpages are displayed in IE9 Standards mode, regardless of the !DOCTYPE directive.

9000 (0x2328) 
Internet Explorer 9. Webpages containing standards-based !DOCTYPE directives are displayed in IE9 mode.

8888 (0x22B8) 
Webpages are displayed in IE8 Standards mode, regardless of the !DOCTYPE directive.

8000 (0x1F40) 
Webpages containing standards-based !DOCTYPE directives are displayed in IE8 mode.

7000 (0x1B58) 
Webpages containing standards-based !DOCTYPE directives are displayed in IE7 Standards mode.

 

参考:

http://www.cnblogs.com/liuzhendong/archive/2012/03/21/2410107.html

 

Webbrowser控件中屏蔽弹出脚本错误对话框

http://www.cnblogs.com/qqflying/archive/2012/07/25/2607881.html

 

经验总结:WebBrowser自动点击弹出提示框alert、弹出对话框confirm、屏蔽弹出框、屏蔽弹出脚本错误的解决办法

http://www.cnblogs.com/qqflying/archive/2012/07/25/2608038.html

 

利用webBrowser获取页面iframe中的内容

 

 [转]如何解决WebBrowser.DocumentCompleted事件的多次调用

 

WebBrowser常用属性方法

 

webBrowser中操作网页元素全攻略

 

Winform 部署mshtml程序集出错的解决方案(该应用程序要求在全局程序集缓存GAC中安装程序集miscrosft.mshtml)

 

http://www.cnblogs.com/liuzhendong/archive/2012/04/27/2474363.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值