Hi,

I have problem with WiX in where I want to include a file into the
setup
only if that file exist. The problem can be illustrated by the
following
WiX-like snippet:

  <Component Id="UserGuide"
Guid="...">
    <?if
FileExist("$(env.SrcDir)\Documentation\Spanish\User
Guide.pdf")?>
      <File
Source="$(env.SrcDir)\Documentation\Spanish\User Guide.pdf"
KeyPath="yes"/>
    <?else?>
      <File
Source="$(env.SrcDir)\Documentation\English\User Guide.pdf"
KeyPath="yes"/>
    <?endif?>
  </Component>

That is, only if the Spanish user guide (pdf) file exist (it may not
be
available due to translation) it should be included into the
setup.
Otherwise the English version should be included.

As far as I'm aware of the FileExist syntax capability (or something
similar) is not available in the preprocessor today. So you can
consider
it a feature request for WiX 3.0. It might not be that hard
to develop the
feature into the 'src\wix\Preprocessor.cs' source
file, probably in the
EvaluateAtomicExpression() method.

But does anybody know how I can achive something like this with todays
WiX?

Thanks in advance for all replies,
/Michael


-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to