Hello,

 I have run into a problem with the foreach preprocessor statement. I get these 
errors (see Compiler output) when I compile this Wix source code (see Wix 
source code). What have I done wrong?

The code has been adjusted before sending and hence the line numbers are wrong.

Thank you,
Radovan

Compiler output

dependent.wxs(11)
: error CNDL0004 : The Data element contains an unexpected attribute 'xmlns'.

dependent.wxs (13)
: error CNDL0004 : The Data element contains an unexpected attribute 'xmlns'.

dependent.wxs (15)
: error CNDL0004 : The Data element contains an unexpected attribute 'xmlns'.

dependent.wxs (17)
: error CNDL0004 : The Data element contains an unexpected attribute 'xmlns'.

 
Wix source code

<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi";>
 <Fragment>
   <CustomTable Id=" Dependency">
   <Row>
    <?foreach DependentCompId in "$(var.DependentCompIds)"?>
    <Data Column="ComponentId">$(var.BaseCompId)</Data>

    <Data Column="DependentCompId">$(var.DependentCompId)</Data>
   <?endforeach?>
   </Row>
  </CustomTable>
</Fragment>

</Wix>


Preproccessed output


<?xml version="1.0" encoding="utf-8"?>
<?ln dependent.wxs*34?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi";>
  <?ln dependent.wxs*36?>
  <Fragment>
    <?ln dependent.wxs*38?>
    <CustomTable Id="Dependency">
      <?ln dependent.wxs*39?>
      <Row>
        <?ln dependent.wxs*41?>
        <Data Column="ComponentId" 
xmlns="http://schemas.microsoft.com/wix/2006/wi";>22BEC269-83AC-4C02-9323-4C556CC959A6</Data>
        <?ln dependent.wxs*42?>
        <Data Column="DependentCompId" 
xmlns="http://schemas.microsoft.com/wix/2006/wi";>29F33D17-CD71-4290-BBFD-A327E2EC1223</Data>
        <?ln dependent.wxs*41?>
        <Data Column="ComponentId" 
xmlns="http://schemas.microsoft.com/wix/2006/wi";>22BEC269-83AC-4C02-9323-4C556CC959A6</Data>
        <?ln dependent.wxs*42?>
        <Data Column="DependentCompId" 
xmlns="http://schemas.microsoft.com/wix/2006/wi";>5BC2D8C3-FA1B-4F2A-BB5B-4DDA7ED965D8</Data>
      </Row>
    </CustomTable>
  </Fragment>
</Wix>

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to