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

Custom Action by Feature

We're upgrading from Installshield 2009 Express to InstallShield 2011 Professional. It's a basic MSI project that I am trying to upgrade.

One thing I have not figured out is how to handle the changes in custom actions. I have a custom action which runs an EXE file, which i need to perform on install and uninstallation, but only if a certain feature is being installed/uninstalled.

I see where to put the action on installation, but I have not figured out how to trigger this only if that feature is installed. In 2009, it was pretty easy to use the dialog box and set a condition that applied to a certain feature.

There was also a section in 2009 for the Uninstall action sequence - how do I do this in 2011?

Thanks for any help you can offer.
Labels (1)
0 Kudos
(3) Replies
wmcdan23
Level 3

I've answered most of my own questions, but I am still not quite sure how to perform a custom action based on what features are being installed.

In my case, I have 4 features n my project. I need to run a program which sets some registry entries, but only if one feature is being installed. I only install that program in that feature.

So, I need to set up a condition on my custom action that says "Only do this if FEATURE3 is being installed". (or if FEATURE3 is being uninstalled, for the removal/rollback actions)

Can anyone help me with this?
0 Kudos
esiemiat
Level 9

For features there are 2 modifiers that you can use. The & indicates you are checking the action state of the feature, and ! indicates you are checking the installed state of the feature.

The following article gives examples of what I am talking about. Hope this helps.

http://msdn.microsoft.com/en-us/library/aa368561(v=vs.85).aspx
0 Kudos
wmcdan23
Level 3

esiemiat wrote:
For features there are 2 modifiers that you can use. The & indicates you are checking the action state of the feature, and ! indicates you are checking the installed state of the feature.

The following article gives examples of what I am talking about. Hope this helps.

http://msdn.microsoft.com/en-us/library/aa368561(v=vs.85).aspx


Thanks! That was exactly what I needed!! 🙂
0 Kudos