This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- Re: RegDBQueryKey cannot get all sub keys
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Jul 23, 2013
10:25 PM
RegDBQueryKey cannot get all sub keys
Hi all,
Thanks a lot in advance for any possible help!
I am using InstallShield professional edition with an evaluation license. The problem I have is that RegDBQueryKey function get cannot find all the sub keys of a registry key.
My codes are:
The running result is:
Is there any special reason for those keys don't show up?
Regards!
Thanks a lot in advance for any possible help!
I am using InstallShield professional edition with an evaluation license. The problem I have is that RegDBQueryKey function get cannot find all the sub keys of a registry key.
My codes are:
function RemoveTarmaInstallation(hMSI)
// To Do: Declare local variables.
STRING szKey, szName, svValue, szMsg;
NUMBER nvType, nvSize;
LIST listNames;
begin
// To Do: Write script that will be executed when MyFunction is called.
if (RegDBSetDefaultRoot(HKEY_LOCAL_MACHINE) < 0) then
MessageBox ("RegDBSetDefaultRoot failed", SEVERE);
endif;
szKey = "SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall";
if (RegDBKeyExist(szKey) < 0) then
SprintfBox (INFORMATION, "Error", "Non-existing key: %s", szKey);
return;
endif;
listNames = ListCreate(STRINGLIST);
if (RegDBQueryKey(szKey, REGDB_KEYS, listNames) < 0) then
SprintfBox (INFORMATION, "Error", "failed to query key: %s", szKey);
return;
else
SdShowInfoList("INFO", "value names", listNames);
endif;
end;
The running result is:
Is there any special reason for those keys don't show up?
Regards!
(1) Reply
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Jul 24, 2013
12:17 AM
I have just figured out the reason.
I tried to read the 64 bit registry keys in my 32 bit installer without setting the registry options. After add the following to my code, everything is OK now:
I tried to read the 64 bit registry keys in my 32 bit installer without setting the registry options. After add the following to my code, everything is OK now:
REGDB_OPTIONS = REGDB_OPTIONS | REGDB_OPTION_WOW64_64KEY;