Showing results for 
Show  only  | Search instead for 
Did you mean: 

Uninstall action not firing...

I'm having no luck getting an uninstall custom action to fire.

The INSTALL custom action is:
InstallDriver.exe -install

This install action is set "After RegisterComPlus" (actually, it can exist anywhere between "After InstallFiles" and "After InstallFinalize"). The action is a "Commit Execution", Synchronous (check exit code), and always executes. The condition for this is: "VersionNT>=500 AND Installed = FALSE"

The UNINSTALL custom action is:
InstallDriver.exe -uninstall

This uninstall action is also a "Commit Execution" type and is set at the "After InstallFiles" sequence. It is also synchronous (check exit code), but the condition is "VersionNT>=500 AND Installed = TRUE". It is set to fire before the install action and is properly being skipped on a fresh install, but on an uninstall, it is not firing.

Any ideas?

(4) Replies
Have you checked the log file that could be created to make sure that the action is being executed on uninstall?
One issue is that MSI properties are generally not set to the values TRUE and FALSE; to see if the property Installed has a value, the condition would be just the property name:


To see if the property is undefined, the condition would be:

Not Installed

You might also find this InstallShield newsletter article useful:
So would the condition statement need to be modified as follows?
(is the syntax correct?)

For install:
VersionNT>=500 AND Not Installed

For uninstall:
VersionNT>=500 AND Installed

Is this right?
I'm the nervous type, so I'd use parentheses:

(VersionNT>=500) And (Not Installed)

but your form should work, too.

If you want to detect a complete uninstall, though, "Installed" isn't enough (it succeeds for any type of maintenance mode); perhaps see that newsletter article for tips about REMOVE="ALL" and the like...