In MSBuild, all properties (declared in PropertyGroups) work the same way
(last one read overrides all previous ones). It is only items (declared in
ItemGroups) that accumulate content.

Thus, the pattern in MSBuild used for accumulating properties is usually:

<PropertyGroup>
  <Property>ItemOne</Property>
</PropertyGroup>
<PropertyGroup>
  <Property>$(Property);ItemTwo</Property>
</PropertyGroup>

Or, if you wish to avoid extraneous ";" marks:

<PropertyGroup>
  <Property>ItemOne</Property>
</PropertyGroup>
<PropertyGroup>
  <Property Condition=" '$(Property)' == '' ">ItemTwo</Property>
  <Property Condition=" '$(Property)' != '' ">$(Property);ItemTwo</Property>
</PropertyGroup>

-Blair

-----Original Message-----
From: Elfe Xu [mailto:elf...@microsoft.com] 
Sent: Tuesday, June 22, 2010 5:26 PM
To: wix-users@lists.sourceforge.net
Subject: Re: [WiX-users] Undefined preprocessor variable error


Interesting. Why is the DefineConstants different with other element suche
as
Property?
I have a file MyProj.WIX.targets, which is used by Setupx64.wixproj and
Setupx86.wixproj. So I could not have my constants definitation partially in
the WIX.targets and partially in the wixproj files, according to whether
they are shared or not. Because one of them will get overwritten.
Althought currently I don't have such a scenario, but this limitation seems
unfriendly to me:(
-- 
View this message in context:
http://windows-installer-xml-wix-toolset.687559.n2.nabble.com/Undefined-prep
rocessor-variable-error-tp5209950p5211321.html
Sent from the wix-users mailing list archive at Nabble.com.

----------------------------------------------------------------------------
--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users


------------------------------------------------------------------------------
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to