With CloseApplication you can shutdown any arbitrary application (not just ones 
you are installing) but you have to determine which ones some other way.

I just did a quick scan of the custom action code associated with 
CloseApplication and it doesn't currently tie into MSIs integration with 
Restart Manager. So, you will need some custom action work (either extend 
CloseApplication, implement an EmbeddedUI, or create/find some other CA).

You don't need to reimplement Restart Manager. Using the Restart Manager APIs 
described in the MSI API docs you have the Restart Manager query the processes 
using your files and add those processes to MSI's own RM session.

Vista RTM and SP1 may have 4.5 but only of it was explicitly installed, so what 
you lose by not having 4.5 is the EmbeddedUI alternative (which gives you the 
process list for "free"). You can do what you want in MSI 4.0 (but it will 
require some CA work).

If you have some budget, I can be hired to provide a CA that performs that task 
for you. It would be up to you if you wished that to be contributed back to the 
community or to have it licensed to you. Email me directly if you are 
interested.

-----Original Message-----
From: i...@roadrunner.com [mailto:i...@roadrunner.com] 
Sent: Monday, June 21, 2010 12:32 PM
To: General discussion for Windows Installer XML toolset.
Cc: Blair
Subject: Re: [WiX-users] Customizing WixUI_FeatureTree


> "Basic UI or Reduced UI level installations give the user the option of
> using the Restart Manager to reduce system restarts even if the
> MsiRMFilesInUse dialog box is not present. Silent UI level installations
> always shut down applications and services, and on Windows Vista, always use
> Restart Manager."
> 
> >From my previous interactions with Windows Installer, if a file isn't
> replaced, Windows Installer doesn't bother with requesting a reboot (it just
> moves the files it couldn't delete to a hidden directory and marks them to
> be deleted on the next system boot). Thus, it may not be engaging RM to
> stop/restart a process that is holding onto a file it doesn't feel requires
> a reboot.

I see, that may explain what's happening. It is still a problem though, because 
the component in question needs other files to function correctly, and they get 
deleted during uninstall. A specific example: The component is a toolbar for 
Explorer. It gets its configuration (what buttons to show) from an ini file. 
Once the ini file is uninstalled, the toolbar will revert to the default 
buttons, which (while not critical) is not nice. Same goes for the localization 
files. Without them the toolbar reverts to English when they are gone.


> CloseApplication may do the job you need. If it doesn't, either it should be
> extended to join processes to the RM session, or another CA would need to be
> used for that task.

Correct me if I'm wrong, but CloseApplication is specifically for EXEs that are 
part of the package, right? I don't know in advance what EXEs will load my DLL.

> Alternately, if you add an embedded UI you could add any processes holding
> files found to be in use to the RM session yourself right from the embedded
> UI (which ironically doesn't have to show any UI at all, and can be run no
> matter what UI level is in play). Of course, embedded UI requires MSI 4.5 or
> higher, which not everyone has (The latest Service Pack for both Vista and
> 2008 have 4.5, but XP SP3 doesn't, although 4.5 is available for XP.
> However, XP doesn't have Restart Manager, so that may be a moot point).

I'm not sure I understand, but are you suggesting I re-implement the Restart 
Manager? (locate all processes that use the DLL, then show a list to the user, 
or try to restart them). BTW, I am targeting Vista and up, and I don't mind if 
the uninstaller does its best on SP2, as long as it works somehow on lower 
service packs.



------------------------------------------------------------------------------
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to