Neil,

I've noticed that design pattern in the IIS extensions as well;  their 
modus operandi in the most recent WiX code I have is to include the 
install state and install action of the related component as part of 
their wrapped query data in the CustomActionData.  I'm not sure the 
reason behind that approach vs. having separate entry points; the 
obvious answer is that there are situations where web components will be 
both installed and uninstalled (maintenance mode? do patches and / or 
upgrades have the same possibility?), and we can be assured that 
everything will be ordered properly in the call to ConfigureIIsExec.  It 
also cuts down on the number of queries against the database and calls 
to CA's.  While I like the idea of discoverability via the conditions in 
the execute sequence table, that gets unduly complicated in light of 
multiple records associated with multiple components that have 
potentially different install states; I guess you would have to split 
things out on a feature by feature / component by component basis.  At 
that point, I'm not sure how you would associate a particular CA call 
with a given feature / component short of adding a whole bunch of 
properties that coincide with the CustomActionData for each CA call 
(which are only available for deferred actions).  Off the top of my 
head, I cannot figure out how one would establish the particular 
execution context (e.g execute sequence) if the same CA was sequenced 
multiple times.

As a side note to the maintainers of the Windows Installer API, gosh it 
it would sure be nice to be able to pass a string argument to a custom 
action via an additional formatted column in the CustomAction table, or 
better yet the sequence tables.  While a similar effect can be achieved 
via custom tables and immediate actions that set the CustomActionData 
for deferred actions, that definitely makes it more complicated, 
especially in light of my thoughts from the previous paragraph.

So, if there is the possibility of having to deal with multiple rows 
with varying install states, you will either need to include the state 
transition information in the CustomActionData or sequence multiple CA's 
that get the proper subsets of the data.  If you wanted to transparently 
condition the CA's, it would look like a god-awful check across multiple 
features and / or components.

Or I could be wrong. <g/>

Thanks,

Thomas S. Trias
Senior Developer
Artizan Internet Services
http://www.artizan.com/



-------- Original Message  --------
Subject: Re: [WiX-users] DTF - install, rollback and uninstall
From: Neil Sleightholm <n...@x2systems.com>
To: General discussion for Windows Installer XML toolset.   
 <wix-users@lists.sourceforge.net>
Date: 2/19/2009 3:41 PM
> I have to admit to being confused! Looking at the built in WiX custom
> actions I see code like this in their wixlibs:
>
> <CustomAction Id=nstallSqlData" BinaryKey="ScaSchedule2"
> DllEntry=nstallSqlData" Execute="immediate" Return="check" />
> <CustomAction Id=ninstallSqlData" BinaryKey="ScaSchedule2"
> DllEntry=ninstallSqlData" Execute="immediate" Return="check" />
>
> <InstallExecuteSequence>
> <Custom Action=ninstallSqlData" Before="RemoveFiles"
> Overridable=es">NOT SKIPUNINSTALLSQLDATA AND VersionNT &gt;
> 400</Custom>
> <Custom Action=nstallSqlData" After="InstallFiles"
> Overridable=es">NOT SKIPINSTALLSQLDATA AND VersionNT &gt; 400</Custom>
> </InstallExecuteSequence>
>
> Where is the detection or conditional calls in that? In most cases this
> seems to end up calling the same code but with a true/false code
> indicating install/uninstall.
>
> Neil
>
> -----Original Message-----
> From: Jason Ginchereau [mailto:jason...@microsoft.com] 
> Sent: 19 February 2009 17:50
> To: General discussion for Windows Installer XML toolset.
> Subject: Re: [WiX-users] DTF - install, rollback and uninstall
>
> Oh. To detect if the product is being uninstalled you need to check the
> REMOVE property: http://msdn.microsoft.com/en-us/library/aa371194.aspx.
> But of course you won't be able to access that from a CA running in
> deferred/rollback/commit mode. 
>
> Typically, uninstall custom actions are conditionally scheduled in the
> sequence table using the REMOVE=L condition, so the CA would not need
> to check for uninstall mode via an API.
>
>
> -----Original Message-----
> From: Neil Sleightholm [mailto:n...@x2systems.com] 
> Sent: Wednesday, February 18, 2009 11:59 PM
> To: General discussion for Windows Installer XML toolset.
> Subject: Re: [WiX-users] DTF - install, rollback and uninstall
>
> I took at look at that and couldn't figure out how you could tell it was
> being called during and uninstall. I am sure I am missing something
> obvious!
>  
> Neil
>  
> Neil Sleightholm
> X2 Systems Limited
> n...@x2systems.com <mailto:n...@x2systems.com> 
>  
>
> ________________________________
>
> From: Jason Ginchereau [mailto:jason...@microsoft.com]
> Sent: Thu 19/02/2009 03:10
> To: General discussion for Windows Installer XML toolset.
> Subject: Re: [WiX-users] DTF - install, rollback and uninstall
>
>
>
> Use Session.GetMode(InstallRunMode) -- it's just a very thin wrapper
> around the MsiGetMode Win32 API
> (http://msdn.microsoft.com/en-us/library/aa370125.aspx)
>
>
> -----Original Message-----
> From: Neil Sleightholm [mailto:n...@x2systems.com]
> Sent: Wednesday, February 18, 2009 2:51 PM
> To: General discussion for Windows Installer XML toolset.
> Subject: [WiX-users] DTF - install, rollback and uninstall
>
> I a DTF authored custom action how can you tell the mode it is running
> in, e.g. install, rollback or uninstall?
>
>
>
> Neil
>
>
>
> Neil Sleightholm
> X2 Systems Limited
> n...@x2systems.com <mailto:n...@x2systems.com>
>
>
>
>
>
> ------------------------------------------------------------------------
> ------
> Open Source Business Conference (OSBC), March 24-25, 2009, San
> Francisco, CA -OSBC tackles the biggest issue in open source: Open
> Sourcing the Enterprise -Strategies to boost innovation and cut costs
> with open source participation -Receive a $600 discount off the
> registration fee with the source code: SFAD http://p.sf.net/sfu/XcvMzF8H
> _______________________________________________
> WiX-users mailing list
> WiX-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wix-users
>
>
>
> ------------------------------------------------------------------------
> ------
> Open Source Business Conference (OSBC), March 24-25, 2009, San
> Francisco, CA
> -OSBC tackles the biggest issue in open source: Open Sourcing the
> Enterprise
> -Strategies to boost innovation and cut costs with open source
> participation
> -Receive a $600 discount off the registration fee with the source code:
> SFAD
> http://p.sf.net/sfu/XcvMzF8H
> _______________________________________________
> WiX-users mailing list
> WiX-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/wix-users
>
>
>   


------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to