RegistryKey extsubkey = Registry.ClassesRoot.OpenSubKey(".doc");
string extdefaultvalue = extsubkey.GetValue(null) as string;
//if (extdefaultvalue.Equals("exefile", StringComparison.OrdinalIgnoreCase)) //扩展名类型是可执行文件
//{
RegistryKey exefilesubkey = Registry.ClassesRoot.OpenSubKey(extdefaultvalue); //从注册表中读取文件类型名称的相应子键
if (exefilesubkey != null)
{
string exefiledescription = exefilesubkey.GetValue(null) as string; //得到exefile描述字符串
}
// }
}