Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

Know if a feature was hidden


3 replies to this topic

Rodolfogd

Rodolfogd
  • Full Members
  • 3 posts

Posted 28 June 2016 - 19:44

In my custom actions I need to know if a feature was hidden, in order to skip the uninstall/remove actions. Is this possible?



deramor

deramor
  • Full Members
  • 187 posts

Posted 28 June 2016 - 22:52

I'm not sure about being visible or not but if your goal was to know if the install state of a feature changed, you can use conditions on your Custom Actions to run or prevent them from running.

 

https://msdn.microso...2(v=vs.85).aspx



Rodolfogd

Rodolfogd
  • Full Members
  • 3 posts

Posted 29 June 2016 - 03:12

My problem is that the Custom Action is always executing even when the condition is not true. Just confirming, I tested with this conditions:
 
INSTALLLEVEL = 0
INSTALLLEVEL = 30578
INSTALLLEVEL = 30579
INSTALLLEVEL = 30580
 
Tried running the installer with that different values and it looks like the InstallShield is ignoring the condition and doing whatever he wants.
 
32e8bac748.png



Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 11 July 2016 - 15:45

The INSTALLLEVEL property is not what you want. Use this:

&NameOfYourFeature = 2

This is true if the feature is being uninstalled.