cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
DangerIsGo
Level 3

Registry System Search doesn't work

I'm trying to create an install condition where the installer will look to see if a registry key exists and if so, continue installing, else it'll pop up a message box saying to the operator that they must install this prerequisite before continuing. I add a System Search to look for a registry key and all I want is for that key to exist. For example,

HKLM\Software\Company\Product

I want the Product key to exist, there could be nothing contained or a child of that key, I don't care. I just want it to exist. So I add a system search for the HLKM root and add the key as SOFTWARE\Company\Product (leaving value blank and keeping 64 portion of the registry unchecked).

I store the value in a PRODUCT property and use it in an install condition: (PRODUCT) with the message "Make sure product is installed before continuing." Well, I do this, and it still cannot find the product even though it is installed. Anyone know what could be causing this? It's incredibly frustrating as Ive been trying to debug this for the past few hours.
Labels (1)
0 Kudos
(2) Replies
KathyMorey
Level 10

You might want to check the documentation, but I think that the AppSearch action (which is what System Search implements) can't find if a key exists, but can only find if a key has a value. In other words, don't look for the root key, look for a key or a string or dword that you know will be populated. the AppSearch action returns the value of the seach in the property, so if there is no value, the property doesn't get created.
0 Kudos
basher590
Level 3

Did this ever resolve your issue?
I have exactly the same problem searching for this key.

SOFTWARE\Microsoft\Microsoft SQL Server\BC\CurrentVersion

and then putting in "Version" as the registry value. I know it exists I can see it and it has a value of 8.05.2309. It is a String value registry entry.

I have logging turned on on my MSI project but it doesn't give any useful info other than the message i set to display when it cannot find this registry entry.

Does anybody have any other insights into this?

Thanks in advance

Chris
0 Kudos