Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- [Setup]
- ; no ArchitecturesInstallIn64BitMode directive is used here, Inno Setup is so in 32-bit mode
- [Code]
- const
- CrystalReportsKey = 'SOFTWARE\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Crystal Reports';
- ...
- begin
- // if we are on 64-bit system
- if IsWin64 then
- begin
- // if the key is found in 32-bit registry view, it means that a 32-bit CR is installed on the
- // system (if the CR does it so; that's what I don't know); HKLM32 == HKLM in 32-bit mode Inno
- // Setup, so you can write HKLM here (but HKLM32 better explains what is done here)
- if RegKeyExists(HKLM32, CrystalReportsKey) then
- MsgBox('32-bit Crystal Reports found.', mbInformation, MB_OK);
- else
- // if the key is found in 64-bit registry view, it means that a 64-bit CR is installed on the
- // system (that's the case on your system)
- if RegKeyExists(HKLM64, CrystalReportsKey) then
- MsgBox('64-bit Crystal Reports found.', mbInformation, MB_OK);
- end
- else
- // we are not on 64-bit system, so there is only one, 32-bit view, which is mapped as HKLM in
- // 32-bit mode Inno Setup
- if RegKeyExists(HKLM, CrystalReportsKey) then
- MsgBox('32-bit Crystal Reports found.', mbInformation, MB_OK);
- end;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement