Hi

Im trying to create a package for an older application that requires some registry permissions to be modified before it will run without the user having admin access to the PC.

I created the package using InstallShield 2008 and included a custom action to run a VB script that executes subinacl.exe and grants the required permissions. The msi copies the subinacl.exe file to the program files directory on the PC first.

This works fine and the application installs and runs well. However it wont Uninstall because the file gets removed before the script runs, which causes the script to error and stop the uninstall process. Can anyone tell me how to prevent the script from running on Uninstall ?
0 Comments   [ + ] Show Comments

Comments

Please log in to comment

Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.

Answers

0
Solved it myself using information found here
http://www.installshield.com/news/newsletter/0212-articles/msiconditions.asp

I used the direct editor on table InstallExecuteSequence to add a Condition to my Action. The Condition is "Not Installed" (without quotation marks).

Note that it is case sensitive. This will allow the Custom Action to run on install but not on Uninstall. The execution scheduling was also set for "Always Execute".
Answered 01/16/2008 by: mikej01
Yellow Belt

Please log in to comment
0

A commonly used condition is ‘Installed’. If this condition returns the value True, then the action is executed.
This condition means that a check is made first to see if the installation has already been performed.

The opposite is ‘NOT Installed’
Adding this condition will executed the Custom Action only if the MSI has not yet been installed.

So, if the action has to execute during an install, NOT Installed should be used.
Installed can be used for a uninstall or repair action.

Another widely used condition employs the REMOVE property. The value of the REMOVE property is a list of features delimited by commas that are to be removed. These features must be present in the Feature column of the Feature table.
If you use REMOVE~=”ALL” on the command line, the installer removes all features having an install level greater than 0.
In this case, the installer does not remove features having an install level of 0
(~ means that the value is not case-sensitive).

When the condition NOT REMOVE~=”ALL” returns the value TRUE, the Custom Action is performed during an installation or a repair action In case of an uninstall we therefore use REMOVE~=”ALL”.[/align]
Answered 01/17/2008 by: Liesje
Yellow Belt

Please log in to comment
0
[nitpick]Be careful with your copying-and-pasting. :)
You said "If you use REMOVE~=”ALL” on the command line...": I'm sure we all know you meant "If you use REMOVE=”ALL” on the command line..." and that 'REMOVE~=”ALL”' is used as a condtion, but someone new to packaging may not know.[/nitpick]
Answered 01/17/2008 by: VBScab
Red Belt

Please log in to comment
Answer this question or Comment on this question for clarity