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?
The MSDN remarks for WebBrowser indicate it rehosts the IE ActiveX control:
The WebBrowser control internally instantiates the native WebBrowser ActiveX control.
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:
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
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