In the code sample where you are trying to use QtExec you are using the 
<Property/> element to set the property that will serve as the command line for 
QtExec. There are two things wrong with that approach.

First the name of the property must match the name of the CustomAtion that you 
will schedule to do the job. In this case the property should be called 
MakeAllApp20.

Second because your command line depends on another property you can't use the 
<Property/> element because that sets property values literally. You need to 
schedule a custom action to set the value of the MakeAllApp20 property. Take a 
look at the <SetProperty/> and <CustomAction/> in the WiX docs.

I think Bob already mentioned that there's something funky with your use of WiX 
variables to condition whether the custom actions exist in your msi package or 
not. You'll probably want to remove those and use some other mechanism to 
determine whether it should run or not.

Edwin G. Castro
Software Developer - Staff
Electronic Banking Services
Fiserv
Office: 503-746-0643
Fax: 503-617-0291
www.fiserv.com
Please consider the environment before printing this e-mail

> -----Original Message-----
> From: Erich Nurr [mailto:erich.n...@gmx.de]
> Sent: Tuesday, April 13, 2010 7:44 AM
> To: wix-users@lists.sourceforge.net
> Subject: [WiX-users] To set property with the value of another
> property, use a CustomAction with Property and Value attributes?!
> 
> 
> Hi !
> here is my Code:
> -------------------------------------------
>     <Property Id="ASPNETREGIIS">
>       <DirectorySearch Path="[FRAMEWORKBASEPATH]" Depth="4"
> Id="FindAspNetRegIis">
>         <FileSearch Name="aspnet_regiis.exe" MinVersion="2.0.5"/>
>       </DirectorySearch>
>     </Property>
> 
>     <?if $(var.ASPNETv1) = "-" AND $(var.ASPNETv2) = "-" ?>
>     <CustomAction Id="MakeAllApp20" Directory="TARGETDIR"
> ExeCommand="[ASPNETREGIIS] -i" Return="check"/>
>     <InstallExecuteSequence>
>       <Custom Action="MakeAllApp20"
> After="InstallFinalize">ASPNETREGIIS AND
> NOT Installed</Custom>
>     </InstallExecuteSequence>
>     <?endif?>
> -------------------------------------------
> this code works fine but by installing the commandprompt is visible and
> thats not what i want...
> so i used the QtExec Command to hide it like this code:
> -------------------------------------------
>     <Property Id="ASPNETREGIIS">
>       <DirectorySearch Path="[FRAMEWORKBASEPATH]" Depth="4"
> Id="FindAspNetRegIis">
>         <FileSearch Name="aspnet_regiis.exe" MinVersion="2.0.5"/>
>       </DirectorySearch>
>     </Property>
> 
>     <?if $(var.ASPNETv1) = "-" AND $(var.ASPNETv2) = "-" ?>
>       <Property Id="QtExecCmdLineNoASPInstalled" Value="[ASPNETREGIIS]
> -i"
> />
>         <CustomAction Id="MakeAllApp20" BinaryKey="WixCA"
> DllEntry="CAQuietExec" Execute="immediate" Return="check"/>
>       <InstallExecuteSequence>
>         <Custom Action="MakeAllApp20" After="InstallFinalize" />
>       </InstallExecuteSequence>
>     <?endif?>
> ---------------------------------------------------
> but there is a warning after built:
> Warning       2       The 'ASPNETREGIIS' Property contains '[ASPNETREGIIS]'
> in its value
> which is an illegal reference to another property.  If this value is a
> string literal, not a property reference, please ignore this warning.
> To
> set a property with the value of another property, use a CustomAction
> with
> Property and Value attributes.
> 
> i runned the msi file and looked into the logfile and the
> [ASPNETREGIIS] is
> empty like the warning told it.
> How to fix this? and why it doesnt work like the code with
> ExeCommand=[ASPNETREGIIS] ?
> 
> Thanks
> Erich Nurr
> --
> View this message in context: http://n2.nabble.com/To-set-property-
> with-the-value-of-another-property-use-a-CustomAction-with-Property-
> and-Value-attrib-tp4896460p4896460.html
> Sent from the wix-users mailing list archive at Nabble.com.
> 
> -----------------------------------------------------------------------
> -------
> Download Intel&#174; Parallel Studio Eval
> Try the new software tools for yourself. Speed compiling, find bugs
> proactively, and fine-tune applications for parallel performance.
> See why Intel Parallel Studio got high marks during beta.
> http://p.sf.net/sfu/intel-sw-dev
> _______________________________________________
> WiX-users mailing list
> WiX-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wix-users
------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to