This was indeed very helpful. I started using conditions such as (&Feature = 3) 
to detect feature's installation and (&Feature = 2) to detect feature removal. 
Big improvement in WiX script structure comparing to what I inherited.

Thanks a lot.




-----Original Message-----
From: Blair Murri [mailto:os...@live.com] 
Sent: Tuesday, January 28, 2014 5:08 AM
To: General discussion for Windows Installer XML toolset.
Subject: Re: [WiX-users] finding out what features are being installed

ADDLOCAL doesn’t have to be set. When costing is done in the UI sequence, the 
result of that costing will be placed into the family of properties that 
includes ADDLOCAL in order to communicate to the execute sequence which 
features are to be changed and how (which causes things like feature 
conditions, installlevel, and parent/child relationships between features to be 
ignored in the execute sequence’s costing). If none of those properties are set 
when the execute sequence starts costing, then those other means of determining 
what to do for each feature are used (as they would have been in the UI 
sequence).




If you want to know what the action and status of each feature are there are 
both APIs and a conditional syntax that will give them to you without having to 
depend on properties like ADDLOCAL. Look at pages like 
http://msdn.microsoft.com/library/aa368012.aspx (Access Prefixes section) when 
using the Condition type in the database (such as in the sequence tables) or 
when using the MsiEvaluateCondition() function in a CA, or more directly by 
using the MsiGetFeatureState() function in a CA.


Blair





From: Marek Mielcarek
Sent: ‎Monday‎, ‎January‎ ‎27‎, ‎2014 ‎3‎:‎06‎ ‎PM
To: General discussion for Windows Installer XML toolset.





To learn what features are being installed I try to examine ADDLOCAL which is a 
standard parameter that can be passed to MSI. I use the following line in my 
WiX xml to do that:
<SetProperty Id="FEATURELIST" Value="[ADDLOCAL]" After="CostFinalize"/>

Then, inside InstallExecuteSequence element I am scheduling custom action which 
uses my local FEATURELIST property.

When I launch the installation with UI (although I have no dialogs), the 
FEATURELIST holds names of all features separated by comma. When I launch 
silent installation (i.e. use /qn switch) the value of FEATURELIST is blank.  
In both cases I do not specify ADDLOCAL, which instructs MSI to install all 
available features.

Why these 2 cases yield different values? I'd always expect the same behavior 
regardless of /qn switch. If that is not the right way, can somebody please 
suggest a reliable way of checking what features are being installed ?
Thank you

------------------------------------------------------------------------------
CenturyLink Cloud: The Leader in Enterprise Cloud Services.
Learn Why More Businesses Are Choosing CenturyLink Cloud For Critical 
Workloads, Development Environments & Everything In Between.
Get a Quote or Start a Free Trial Today. 
http://pubads.g.doubleclick.net/gampad/clk?id=119420431&iu=/4140/ostg.clktrk
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users
------------------------------------------------------------------------------
WatchGuard Dimension instantly turns raw network data into actionable security 
intelligence. It gives you real-time visual feedback on key security issues and 
trends.  Skip the complicated setup - simply import a virtual appliance and go 
from zero to informed in seconds.
http://pubads.g.doubleclick.net/gampad/clk?id=123612991&iu=/4140/ostg.clktrk
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users
------------------------------------------------------------------------------
WatchGuard Dimension instantly turns raw network data into actionable 
security intelligence. It gives you real-time visual feedback on key
security issues and trends.  Skip the complicated setup - simply import
a virtual appliance and go from zero to informed in seconds.
http://pubads.g.doubleclick.net/gampad/clk?id=123612991&iu=/4140/ostg.clktrk
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to