Inno Setup doesn't allow access to all registry keys, why?

Viewed 12424

I use this code to know if a key exists or not:

if RegKeyExists(HKEY_LOCAL_MACHINE, 'Software\Autodesk') then
begin
  MsgBox('Key exists!!', mbInformation, MB_OK);
end;

for this example, it works, I have the message box, but with this it doesn't:

if RegKeyExists(HKEY_LOCAL_MACHINE, 'Software\Autodesk\Maya') then
begin
  MsgBox('Key exists!!', mbInformation, MB_OK);
end;

But the Maya key exists on my computer. Can anybody help me?

EDIT :

In fact, it seems that Inno Setup don't access to the right keys...
For example, with this code I list all the subkeys of HKEY_LOCAL_MACHINE\SOFTWARE, but (!) the result is all subkey of HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node ...

if RegGetSubkeyNames(HKEY_LOCAL_MACHINE, 'SOFTWARE', Names) then
begin
  S := '';
  for I := 0 to GetArrayLength(Names)-1 do
    S := S + Names[I] + #13#10;
  MsgBox('List of subkeys:'#13#10#13#10 + S, mbInformation, MB_OK);
end;

Why this Wow6432Node key?

3 Answers
Related