问题描述
|
这个问题已经在这里有了答案:
解决方法
您可以从注册表中读取版本:
var ieVersion = Registry.LocalMachine.OpenSubKey(@\"Software\\Microsoft\\Internet Explorer\").GetValue(\"Version\");
, 在Windows 8中,您应该使用\“ svcVersion \”而不是\“ Version \”键。否则,它将报告已安装IE 9而不是IE10。如果您已升级到IE10,则Windows 7也可能会发生这种情况(我安装了IE 9,所以不能肯定地说)。
, 我认为这可能会有所帮助:
private string GetIEVersion()
{
string key = @\"Software\\Microsoft\\Internet Explorer\";
RegistryKey dkey = Registry.LocalMachine.OpenSubKey(key,false);
string data = dkey.GetValue(\"Version\").ToString();
return data;
}
, 查看HKEY_LOCAL_MACHINE \\ Software \\ Microsoft \\ Internet Explorer \\ Version注册表项