using Microsoft.Win32;
public bool findSoftwareInstalled()
{
try
{
RegistryKey regkey = Registry.LocalMachine.OpenSubKey("SOFTWARE", true).OpenSubKey(@"Microsoft", true).OpenSubKey(@"Office", true).OpenSubKey(@"Word");
if (regkey == null)
{
return false;
}
else
{
return true;
}
}
catch (Exception ex)
{
Console.WriteLine(ex.Message.ToString());
return false;
}
}
全站熱搜
留言列表