Put it in its own component. <Component Id="UpdateWebConfig" Guid="PLACE_GUID_HERE" .../> <Condition><![CDATA[CLIENTNAME<>SOMECLIENT]]></Condition> <util:XmlFile Id="UpdateWebConfig" File="[ServiceInstanceDirectory]Web.config" Action="setValue" ElementPath='/configuration/appSettings/add[...@key="SomeKey"[\]]' Name="value" Value="SomeValue" /> </Component>
>From there, mark the component transitive or not as is appropriate, etc. -----Original Message----- From: Scott Vickery [mailto:svick...@cavucorp.com] Sent: Tuesday, October 27, 2009 11:32 AM To: wix-users@lists.sourceforge.net Subject: [WiX-users] util:XmlFile, conditionally set value Any ideas on how to conditionally set a value in an xml? Based on a global variable, CLIENTNAME, I want to set a value in a web.config. Something like the following, but, I know it does not work: <Condition Level="0"><![CDATA[CLIENTNAME<>SOMECLIENT]]> <util:XmlFile Id="UpdateWebConfig" File="[ServiceInstanceDirectory]Web.config" Action="setValue" ElementPath='/configuration/appSettings/add[...@key="SomeKey"[\]]' Name="value" Value="SomeValue" /> </Condition> Thanks, Scott ---------------------------------------------------------------------------- -- Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users ------------------------------------------------------------------------------ Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ WiX-users mailing list WiX-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wix-users