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

Installed Component recognition during modify


9 replies to this topic

rakeshkr

rakeshkr
  • Full Members
  • 14 posts

Posted 18 January 2007 - 12:56

Hi All,
I have a doubt regarding the modify scenario of basic MSI installer.
When we install a product containing more than one compoents but selecting only few of them and later run the installer in maintenence mode, then during this time how does installer understand which components are installed and which are not installed.

The reason i have a doubt here is because say i have two version (v1 and v2) of a product and if i installed new version (v2) product but installed only few components, later i run the old version of product (v1) and installed few components, and finally i run the v2 version of installer in maintence mode, but during Modify scenario it does not show the components installed using v1 version of product rather only show the components instlled using v2 version of the product.

Please help...

Thanks in advance.

Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 20 January 2007 - 20:01

You can't select components for instalaltion, only features.
Your sceanrio will depend on the type of update you are doing: Major (ProductCode changed) or Minor (both versions use the same ProductCode).

rakeshkr

rakeshkr
  • Full Members
  • 14 posts

Posted 22 January 2007 - 07:11

I am sorry, i used wrong keyword to explain the problem. From components i meant the features.
When we have more than one feature in a product and we install only few of them and later when we run the installer in maintence mode it shows us what features are installed and what are still not installed.
This scenario is not major or minor upgrade i suppose. but the same question i have for major and minor upgrade also.

Please help...
Thanks in advance.

Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 22 January 2007 - 21:37

Windows Installer keeps track of installed features using (undocumented) registry entries. This information is used in maintenance mode and during minor updates, but can also be used in Major Upgrades. In this case the MigrateFeatureStates action uses the information to select the appropriate features in the new version.

rakeshkr

rakeshkr
  • Full Members
  • 14 posts

Posted 23 January 2007 - 08:08

I have one more doubt. If condition of a CA(InstallShield default) is not set then does it mean, this CA will always execute or will never execute?

I think same should be valid for user defined CA also.

Please help...

Thanks in advance...

Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 23 January 2007 - 15:23

If a custom action doesn't have a condition it will always be executed (if it's ini both the UI and Execute sequence it may execute only once, depending on the scheduling settings).

joey81

joey81
  • Full Members
  • 12 posts

Posted 26 February 2007 - 00:44

Hello,

I agree with rakeshkr, for I seem the have a similar or even the same problem.

In a Next-Button I use a condition of the structure

(&Feature1 = 3) and (&Feature2 <> 3)

to spawn a dialog. Meaning Feature1 depends on Feature2 beeing installed, too.

The condition works fine during the installation sequence.
But if DEselecting Feature1 while installing Features2, the dialog is spawned, when trying to add Feature1 in Maintenance-Mode, even though Features 2 is allready installed.

I've added a (NOT Installed) to the condition, so it doesn't grip when in Maintenance-Mode, but I'm hoping for a final solution coming from Macrovision.

Always thankful for any new insight or workaround-ideas.

joey

Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 26 February 2007 - 11:50

&FeatureName=3 is true if the feature is being installed (Feature Action) in the current transaction. In your case it is already installed so this condition is false. In this case however this will be true:
!FeatureName=3
(Feature State)

So your condition to diaplay an error dialog if Feature1 is or will be installed without Feature2 would look like this (ignoring the Advertise and Run from Source options):

(&Feature1=3 Or (!Feature1=3 And &Feature1<>2)) And Not (&Feature2=3 Or (!Feature2=3 And &Feature2<>2))

which means:
&Feature1=3 - feature is being installed
!Feature1=3 - feature is already installed
&Feature1<>2 - feature is not being removed

joey81

joey81
  • Full Members
  • 12 posts

Posted 01 March 2007 - 12:28

Thanks alot! It runs just fine :-)

One question though: Why doesn't the condition work when I include the "Not (&Feature2=3 Or (!Feature2=3 And &Feature2<>2))"-statement in the "feature condition builder" of feature1?

Much obliged for an answer!
Joey

Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 01 March 2007 - 17:38

I'm sorry but I don't understand this question. What doesn't work, and how does it fail?