phil.wilson at mvps.org
Tue Apr 26 10:01:56 PDT 2016
I remember dealing with the spurious FilesInUse record in an external record
handler. The spurious half-empty record has a data size of zero - that's how
I filtered it out. Each in-use entry in a formatted record has two size
fields. If the first of these is zero then skip over it because it's not
relevant. I haven't looked at the WiX handling of these records but if
there's any record size info passed to your code then see if there are any
From: wix-users [mailto:wix-users-bounces at lists.wixtoolset.org] On Behalf Of
Sent: Monday, April 25, 2016 11:21 PM
To: WiX Toolset Users Mailing List
Subject: Re: [wix-users] ExecuteFileInUse
I handled similar issue in my MBA where Bundle was uninstalled while main
application was running and it uninstalled successfully. So team asked me to
check if main application is running. To achieve this, in my Wix markup, I
added a C# custom action to check if MainApp.exe is running and so prompt
user to close it or cancel installation.
<Custom Action="CloseAppsPrompt" After="CostFinalize"/>
But never tried to capture FileInUse in MBA....
On 25 April 2016 at 20:49, Rob Mensching <rob at firegiant.com> wrote:
> Annoying specifics of the Windows Installer behavior showing through.
> Short replies here. Complete answers over there:
> -----Original Message-----
> From: wix-users [mailto:wix-users-bounces at lists.wixtoolset.org] On
> Behalf Of Parkes, Kevin
> Sent: Monday, April 25, 2016 8:48 AM
> To: wix-users at lists.wixtoolset.org
> Subject: [wix-users] ExecuteFileInUse
> I am trying to add support for Files In Use to my MBA and I see my
> ExecuteFilesInUse gets called twice:
> - the first time, event args Files list contains what appears to be
> the PID of the running app, the Window title and 6 empty strings
> - the second time, Files list contains 2 strings: Window title and
> Window title with " (Process Id: nnnn)" appended.
> I've looked at the WiX sources but I can't quite figure out what's going
> 1) why 2 calls?
> 2) will there always be 2 calls? Can I reliably "ignore" one and
> only display an "in use" message in the other?
> 3) can I "fix" it so I only get 1 call?
> 4) is there an (simple) example anywhere implementing ExecuteFilesInUse?
> 5) any guidelines for handling Files In Use in an MBA?
> Kevin Parkes
> WiX Toolset Users Mailing List provided by FireGiant
WiX Toolset Users Mailing List provided by FireGiant
More information about the wix-users