Jens,

        I believe a component condition using an ampersand (&) for the action 
state of the features should be sufficient.  Taking a look at 
http://msdn.microsoft.com/en-us/library/windows/desktop/aa368012%28v=vs.85%29.aspx
 (Conditional Statement Syntax), the WiX code would look something like this:

<Component Id=...>
        <Condition>
                <![CDATA[(&Feature1 > 2) AND (&Feature2 > 2)]]>
        </Condition>
</Component>

        If you want the component to be installed only if the features are 
installed locally and not from source, change the "> 2" to "= 3" for both 
features.  I hope this helps.

David J. Antoine
Quality Assurance
ConvergEx Group | RealTick

-----Original Message-----
From: Jens Teutenberg [mailto:jens.teutenb...@t-online.de]
Sent: Saturday, June 16, 2012 12:05 PM
To: wix-users@lists.sourceforge.net
Subject: [WiX-users] Request feature action in component condition

I want to install a component only if two defined features will be installed. I 
defined a component condition which requests the feature actions. Because the 
feature action will have the correct status after the CostFinalize action I 
wrote my own CustomAction which calls the CostInitialize and CostFinalize 
action before the CostInitialize action. But that don't have the expected 
result. The condition is still false. Additionaly I get the following error 
during the second call of the CostInitialize action: DEBUG: Error 2705: Invalid 
table: Component; Could not be linked as tree.
Is there any hint to use the feature action status in a component condition?
Or is there an other way to solve my problem?

DTF, WiX 3.5, .NET 2.0, Windows Installer 4.5
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and threat 
landscape has changed and how IT managers can respond. Discussions will include 
endpoint security, mobile security and the latest in malware threats. 
http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users
This electronic mail message and any attached files contain information 
intended for the exclusive use of the individual or entity to whom it is 
addressed and may contain information that is proprietary, privileged, 
confidential and/or exempt from disclosure under applicable law. If you are not 
the intended recipient, you are hereby notified that any viewing, copying, 
disclosure or distribution of this information may be subject to legal 
restriction or sanction. Please notify the sender, by electronic mail or 
telephone, of any unintended recipients and delete the original message without 
making any copies.

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to