![]() Key.SetValue(appName, 99999, RegistryValueKind.DWord) Īccording to what I read here ( Controlling WebBrowser Control Compatibility: Using (var Key = Explorer\Main\FeatureControl\FEATURE_BROWSER_EMULATION", true)) You may face a problem for in comparability of windows 10, may due to your website itself ![]() WebBrowserHelper.FixBrowserVersion("SomeAppName",intIeVer) WebBrowserHelper.FixBrowserVersion("SomeAppName") Using of class as followed WebBrowserHelper.FixBrowserVersion() this is why we try with both LOCAL_MACHINE and CURRENT_USER some config will hit access rights exceptions (root Explorer\Main\FeatureControl\FEATURE_BROWSER_EMULATION", appName, ieVer) Private static void FixBrowserVersion_Internal(string root, string appName, int ieVer) Public static void FixBrowserVersion(string appName, int ieVer)įixBrowserVersion_Internal("HKEY_LOCAL_MACHINE", appName ".exe", ieVer) įixBrowserVersion_Internal("HKEY_CURRENT_USER", appName ".exe", ieVer) įixBrowserVersion_Internal("HKEY_LOCAL_MACHINE", appName ".vshost.exe", ieVer) įixBrowserVersion_Internal("HKEY_CURRENT_USER", appName ".vshost.exe", ieVer) Public static void FixBrowserVersion(string appName)įixBrowserVersion(appName, GetEmbVersion()) String appName = System.IO.Path.GetFileNameWithoutExtension(().Location) This is a class will get the latest version of IE on windows and make changes as should be public class WebBrowserHelper You may need to add a line in the Manifest File to avoid errors due to permissions of change in registry: The setup application will change the registry. Reference: MSDN: Internet Feature Controls ![]() Standards-based !DOCTYPE directives are displayed in IE9 mode.Ĩ888 (0x22B8) - Webpages are displayed in IE8 Standards mode,Ĩ000 (0x1F40) - Webpages containing standards-based !DOCTYPEħ000 (0x1B58) - Webpages containing standards-based !DOCTYPEĭirectives are displayed in IE7 Standards mode. Standards mode, regardless of the !DOCTYPE directive.ĩ000 (0x2328) - Internet Explorer 9. Defaultĩ999 (0x270F) - Internet Explorer 9. !DOCTYPE directives are displayed in IE10 Standards mode. Mode, regardless of the !DOCTYPE directive.ġ0000 (0x2710)- Internet Explorer 10. Standards-based !DOCTYPE directives are displayed in IE11 edge mode.ġ0001 (0x2711)- Internet Explorer 10. Webpages are displayed in IE11Įdge mode, regardless of the !DOCTYPE directive.ġ1000 (0x2AF8) - Internet Explorer 11. You may find messagebox.show, just for testing.ġ1001 (0x2AF9) - Internet Explorer 11. MessageBox.Show("Application Settings Failed") MessageBox.Show("Application Settings Failed, Ref: " FindAppkey) MessageBox.Show("Application Settings Applied Successfully") Regkey.SetValue(appName, unchecked((int)0x1F40), RegistryValueKind.DWord) įindAppkey = Convert.ToString(Regkey.GetValue(appName)) If a key is not present add the key, Key value 8000 (decimal) MessageBox.Show("Required Application Settings Present") String FindAppkey = Convert.ToString(Regkey.GetValue(appName)) MessageBox.Show("Application Settings Failed - Address Not found") if the user haven't priviledges to access the registry Regkey = Explorer\\Main\\FeatureControl\\FEATURE_BROWSER_EMULATION", true) Private void SetIE8KeyforWebBrowserControl(string appName) Var appName = Process.GetCurrentProcess().ProcessName ".exe" You may put in setup or check it in start-up of your application: private void Form1_Load(object sender, EventArgs e) NET 4 and am using 64x OS so kindly check this. I think it's right, but it did not I work for me.
0 Comments
Leave a Reply. |