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

How do I enable CA only at upgrade?


3 replies to this topic

uljo2

uljo2
  • Full Members
  • 7 posts

Posted 29 September 2008 - 13:53

Hi,

If I only want to execute a custom action at first installation of a product I use
NOT Installed as a condition in the script.

and if I want to do it at first installation and removal of the product I can write
(( NOT Installed ) OR ( REMOVE~="ALL" ))

But how do i write a condition for the case where I want to execute the CA at first install and at upgrade ?


BR Ulf


uljo2

uljo2
  • Full Members
  • 7 posts

Posted 30 September 2008 - 09:49

Hi,

Now I know.

Use the ActionProperty from the Ugrade table. In my installation it is called.

UPGRADE_1

It's either null or contains the upgrade GUID if it has been detected.


((NOT Installed) OR (UPGRADE_1))

/Ulf

Glytzhkof

Glytzhkof
  • Moderators
  • 1,447 posts

Posted 01 October 2008 - 09:52

There is also the built in UPGRADINGPRODUCTCODE property.

The most common property checks:
* REMOVE = ALL
* Installed
* UPGRADINGPRODUCTCODE

Just from memory (correct me if I am wrong guys, I haven't run testing on this - just want you to have a list to look at in case you need a different condition):
* (REMOVE = ALL) is true for uninstall.
* (Not Installed) is true for a fresh install or a major upgrade.
* (Not Installed) AND (NOT UPGRADINGPRODUCTCODE) is true for a fresh install.
* (Installed) AND (NOT REMOVE = ALL) indicates a minor upgrade or (self)repair.
Regards
-Stein Åsmul

Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 04 October 2008 - 15:47

UPGRADINGPRODUCTCODE will be set during a Major Upgrade but in the old version which is being removed. It's not set in the new version which is being installed.