Monday, March 26, 2012

WebBrowser control tweak

You may tweak the WebBrowser control in case it does not binding to the latest IE version (ie, different from the installed IE).

Below is the registry to be modify:

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BROWSER_EMULATION]
"contoso.exe"=dword:00002328

The values for 'contoso.exe':

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.

References:

For discussion, see here:
http://stackoverflow.com/questions/4612255/regarding-ie9-webbrowser-control

For the MSDN reference, see here:
http://msdn.microsoft.com/en-us/library/ee330730%28VS.85%29.aspx#browser_emulation

No comments:

Post a Comment