Archive: Find if some software is installed


Find if some software is installed
When creating a installer for some prerequisites in my app I went into to scripts these scripts:

I need to know if certain software is installed on the system before takin any action, particularly I need to know if "Microsoft Visual J#® 2.0 Redistributable Package" is installed.

I found these lines in the scripts mentioned above but I dont know how can I use them to verify if the software I want is installed:

System::Call "mscoree::GetCORVersion(w .r0, i ${NSIS_MAX_STRLEN}, *i r2r2) i .r1 ?u"

ReadRegStr $R0 HKCR "CLSID\{D27CDB6E-AE6D-11cf-96B8-444553540000}" ""

Any help? Please...

I found another script and I tried to guess how could I use the ReadRegDWORD to verify the Visual J# Installation. I checked the registry and found a key in "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Visual JSharp Setup\v2.0.50727" named Install with value 1 (hex), but when I try this I always get an error flag:

ReadRegDWORD $0 HKLM "SOFTWARE\Microsoft\Visual JSharp Setup\v2.0.50727" "Install"
IfErrors ErrorI 0

If I'm not wrong, I should only jump to ErrorI if the key isn't found, but I'm trying it on a machine in wich I have it installed.

Please somebody help


I have Visual J# 1.1 and seems that in my X:\WINDOWS\Microsoft.NET\Framework\v1.1.4322 vjc.exe, maybe you should try the same in the .NET 2.0 folder


Now I know what was wrong: I was looking a registry key in "SOFTWARE\Microsoft\Visual JSharp Setup\v2.0.50727", when the key actually is in "SOFTWARE\Microsoft\Visual JSharp Setup\Redist\v2.0.50727".
I missed the "Redist" part, but I guess I was tired. Sorry