问题描述
环境:win7 64位
目标:找到Pc-doc(一种软件)在注册表中的位置,如程序&特征 .我需要确保将其安装在Program&处于后台的功能.
位于HKEY_LOCAL_MACHINE \ SOFTWARE \ Microsoft \ Windows \ CurrentVersion \ Uninstall
我看到了.
我使用
RegistryKey subKey = Registry .LocalMachine.OpenSubKey(@``SOFTWARE \ Microsoft \ Windows \ CurrentVersion \ Uninstall'');
,甚至可以使用SOFTWARE \ Wow6432Node \ Microsoft \ Windows \ CurrentVersion \ Uninstall.功能
1.
HKEY_LOCAL_MACHINE \ SOFTWARE \ Microsoft \ Windows \ CurrentVersion \ Uninstall:
对于使用InstallShield进行安装的用户
2. HKEY_CLASSES_ROOT \ Installer \ Products
3. HKEY_CURRENT_USER \ Software \ Microsoft \ Installer \ Products:
对于那些使用Windows Installer作为Office进行安装的用户.
我列举了3个以上的密钥路径,没有返回想要的结果.
Environment:win7 64bit
Target: Find where Pc-doc(a software) is in Registry ,which is shown on Program & Features . I need to ensure it is installed on Program & Features at background.
it is at HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall
I see it is there.
i use
RegistryKey subKey = Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall");
string[] allSubKeys = subKey.GetSubKeyNames();
No pc-doc is in allSubKeys, even use SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall.
I got another info, There are 3 section to store items shown in Program & Features
1.
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall:
For those using InstallShield to install
2. HKEY_CLASSES_ROOT\Installer\Products
3. HKEY_CURRENT_USER\Software\Microsoft\Installer\Products:
For those using Windows Installer to install ,as Office。
I've enumerate above 3 key path ,no wanted result is returned.
推荐答案
这篇关于指定的密钥在哪里???的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!