cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
LisDani21
Level 2

System Search Help!!!

Ok, I've read all the threads regarding this issue, but I still cannot figure mine out. 😞

I need to Search for a registry key with a specific value and IF it exists, abort, if it does NOT exist, then continue with installation.

I have created a SYSTEM SEARCH with for a reg key: HKCU->SOFTWARE\MYSOFTWARE\VERSION_INSTALLED They Key is 7.3. I choose to store it in HIGHERVERSIONINSTALLED and set it as a Launch Condition called HIGHERVERSIONINSTALLED. In the condition builder, I put: HIGHERVERSIONINSTALLED=TRUE Message: A higher version of the application is already installed on the machine. You must first uninstall the application before re-installing this version.

No matter what I do whether the registry entry exists or not, it aborts the installation with my message. Even if it does NOT exist.

AppSearch is located before LaunchConditions. (Defualt) I did not touch this.

What am I doing wrong??? i Need this to work asap!!

Any help would be appreciated.

Thanks.
Labels (1)
0 Kudos
(4) Replies
meenapanchu
Level 3

I had similar problems
you cam make sure if your property has value
you can insert an VB Script like
Session.Property("PropertNAme") and check if you have any values
The System Search gets executed After APPSearch so make sure you have the CA after that
and in your condition you need to have "" i think because ur registry value is string
0 Kudos
KathyMorey
Level 10

The property you set in System Search will contain the value in your registry key. If the key doesn't exist, the property won't exist. So, in your Launch Condition, all you have to check for is the existence of the property; it's never going to "=TRUE". So in the condition builder, just put the name of the property.
0 Kudos
fgaudet
Level 3

Assuming you're using a MSI project, I had a similar problem too, and here is the cause:
InstallShield support told me all System Searches are done after the 'CostFinalize' step, so trying to use any values from a System Search before that step will fail. (think it could've been mentionned somewhere in the help/System Search View description? Yeah, me too...)

You have two solutions:
1 - Either put your CA just after the 'CostFinalize' step or,
2 - Build a CA running an InstallScript that will read the registry itself and set the property itself.

Personnaly I think the first solution is better - not even shure about the second, one... (but then, I am completely newb with IS2008/MSI and have a bunch of problems of my own 😄 )

Best of luck!
0 Kudos
KathyMorey
Level 10

I don't know where the disconnect was, but that is not true. System searches are done by the AppSearch action, which is one of the first ones done. You can't set a directory using the type 35 custom action until after CostFinalize, so if you want to use the result of a system search to set a directory, you must schedule that after CostFinalize. But the values from the AppSearch action will be available to you as soon as that action is completed.
0 Kudos