WPF web浏览器浏览器版本 [英] WPF WebBrowser Browser Version

查看:567
本文介绍了WPF web浏览器浏览器版本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

请问WPF WebBrowser控件取决于所安装在用户的计算机上的IE版本,或者它使用一个单独的库,跨机器是否一致?我读过,它只是呈现在IE7模式,但我要确保不会有与谁或者不具有IE浏览器安装或仍然在IE6由于某种原因,用户的任何问题。

Does the WPF WebBrowser control depend on the version of IE that is installed on the user's machine, or does it use a separate library that is consistent across machines? I've read that it only renders in IE7 mode, but I want to make sure there wouldn't be any issues with a user who either doesn't have IE installed or is still on IE6 for some reason.

推荐答案

借助 MSDN备注对于web浏览器表明它主机切换IE的ActiveX控件:

The MSDN remarks for WebBrowser indicate it rehosts the IE ActiveX control:

WebBrowser控件内部实例化本地的WebBrowser ActiveX控件。

The WebBrowser control internally instantiates the native WebBrowser ActiveX control.

web浏览器ActiveX控件更好地称为的Shdocvw.dll 。这反过来又包裹的Mshtml.dll ,也许其他DLL的特定环境。 重新托管这种控制的一个需要注意的是其浏览器仿真

The WebBrowser ActiveX control is better known as Shdocvw.dll. This in turn wraps Mshtml.dll, and probably other DLL's given your environment. One caveat of rehosting this control is its setting for Browser Emulation:

有关承载WebBrowser控件的应用程序,默认值为 7000 。要通过使用注册表来控制该功能的价值,添加的名字您的可执行文件的下列设置,设置的值以符合所需的设置。

For applications hosting the WebBrowser Control, the default value is 7000. To control the value of this feature by using the registry, add the name of your executable file to the following setting and set the value to match the desired setting.

0x7000 表示IE7兼容模式。因此,如果你想你的WPF应用程序使用一些其他的方式来渲染你需要更新注册表,如<一个href=\"http://blogs.msdn.com/b/ie/archive/2009/03/10/more-ie8-extensibility-improvements.aspx\">adapted从这个例子

0x7000 means IE7 compatibility mode. Therefore, if you would like your WPF application to render using some other mode you need to update the registry, as adapted from this example:

[HKEY_LOCAL_MACHINE\Software\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BROWSER_EMULATION] 
"MyApplication.exe" = dword:2328

这篇关于WPF web浏览器浏览器版本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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