I think you want something like:

    <CustomAction Id="setJVMpath1" Property="JVMPATH" Value="[JDKHOME15]" 
Execute="firstSequence">JDKHOME15 AND NOT JVMPATH</CustomAction>
    <CustomAction Id="setJVMpath2" Property="JVMPATH" Value="[JREHOME15]" 
Execute="firstSequence">JREHOME15 AND NOT JVMPATH</CustomAction>

    <InstallUISequence>
      <Custom Action="setJVMpath1" After="AppSearch"/>
      <Custom Action="setJVMpath2" After="setJVMpath1"/>
    </InstallUISequence>
 
    <InstallExecuteSequence>
      <Custom Action="setJVMpath1" After="AppSearch"/>
      <Custom Action="setJVMpath2" After="setJVMpath1"/>
    </InstallExecuteSequence>
 
of course, with more than just the two actions.

However, I'm by no means an expert and haven't even tried compiling this, 
so it's very possible I'm heading you down the wrong path.

Kelly




Chris Ridd <[EMAIL PROTECTED]>

Sent by: [EMAIL PROTECTED]
09/27/2007 10:09 AM

To
Kelly Leahy <[EMAIL PROTECTED]>
cc
[EMAIL PROTECTED], wix-users@lists.sourceforge.net
Subject
Re: [WiX-users] Searching for multiple registry keys







On 27 Sep 2007, at 17:59, Kelly Leahy wrote:

>
> Oops.  Sorry Chris for the duplicate - I forgot to reply to all on 
> the first one.

Not a problem - I'll put my reply to you below for everyone's benefit.

> Here's what I sent to Chris - others, tell me if this won't work, 
> because I may need this approach myself, later in my installer 
> building process.
>
> You could do custom actions that set another property based on its 
> previous existence...
>
> consider a property named JVMHOME.  Don't initialize (or create) it.
>
> Write custom actions conditioned on JVMHOME existing, that in 
> sequence set the JVMHOME to another value if the appropriate 
> variable is set.
>
> For instance:
>
> <CustomAction Id="setJVMpath1" Property="JVMPATH" 
> Value="[JDKHOME15]" ...>JDKHOME15 AND NOT JVMPATH</CustomAction>
> <CustomAction Id="setJVMpath2" Property="JVMPATH" 
> Value="[JREHOME15]" ...>JREHOME15 AND NOT JVMPATH</CustomAction>
> ...
>
> I think this will work.  The ... in the <> are there because I 
> don't know what other properties you need to make this go into the 
> proper sequence etc.  If you use this approach, please post back 
> (or reply to me) with the proper complete set of attributes so I'll 
> know the next time.
>
> Kelly

That looks like a much more promising approach than mine :-)

I haven't had to use CustomActions before - do I need to do anything 
special (apart from putting them inside the <Product>) to make them 
work?

Cheers,

Chris


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users




**************************************************************************************
This communication is intended solely for the addressee and is
confidential. If you are not the intended recipient, any disclosure, 
copying, distribution or any action taken or omitted to be taken in
reliance on it, is prohibited and may be unlawful.  Unless indicated
to the contrary: it does not constitute professional advice or 
opinions upon which reliance may be made by the addressee or any 
other party, and it should be considered to be a work in progress.
Unless stated otherwise, this communication does not form a prescribed
statement of actuarial opinion under American Academy of Actuaries 
guidelines.
**************************************************************************************
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to