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

Which Prerequisite Return Codes Indicate Failure?

I'm currently trying to add a prerequisite that essentially ensure the system is in a state that's safe for installation of my other prerequisites (I ran into some trouble with some of them when Windows Update is installing things, so the prerequisite makes sure the WUA is not busy, then pauses it). This prerequisite is a simple application that analyzes the system, displays a message to the user if anything is wrong, then returns 0 if it is safe to continue with the other prerequisites, or some other value if not.

I originally expected Installshield to interpret a return code of "0" as success, and any other return code (other than the ones specified as "reboot required" codes) as failure. Testing indicates this isn't the case, however - Installshield lists the prerequisite as successful even if it returned something other than "0". I've also tried using the standard Windows Installer error code "1603" (ERROR_INSTALL_FAILURE), which was also ignored.

I'm sure I've seen other prerequisites fail from time to time. Is there a particular return code I need to use in order to make Installshield understand that this one did not succeed?
Labels (1)
0 Kudos
(4) Replies
DebbieL
Level 17

After an attempt to install a prerequisite, the conditions that were set on the Conditions tab in the Prerequisite Editor are re-evaluted. The If, after installing the prerequisite, the conditions still indicate it is required setting on the Behavior tab is where you indicate how you want the installation to proceed. For more details, see http://helpnet.macrovision.com/Robo/BIN/Robo.dll?tpc=/robo/projects/installshield14helplib/UIRefPrereqEditor_Behavior.htm.

Debbie Landers
Macrovision Corporation
0 Kudos
jsn_segal
Level 3

So, there's no way to do this with return codes?

I don't think setting some sort of registry flag will work in this case, since I want this prerequiste to run before any other each time the installer starts, instead of just making sure it is run at least once on the target machine.
0 Kudos
DebbieL
Level 17

I can't think of a way you could use the return codes. I just logged this as feature request IOC-000067451 in our internal tracking system, so that we can consider adding it for a future release.

Debbie Landers
Macrovision Corporation
0 Kudos
jsn_segal
Level 3

I did a little more research, and it looks like prerequisite return codes are only checked when the prerequisite launches an MSI file.

Thanks for logging the feature request - it would be helpful to be able to specify failure (or success) return codes for normal executables instead of just reboot return codes.

It seems I'll have to find some other way to do this for now, though. Here's my current plan, just in case anyone else has this problem - I'm going to have the Installshield-generated Setup.exe launched by another executable that verifies the safety of the system state. (This is basically just another external bootstrapper - like the ones the prerequisites originally helped eliminate.)
0 Kudos