What does WIX's CloseApplication functionality do and how would can the application respond to such
Posted
by tronda
on Stack Overflow
See other posts from Stack Overflow
or by tronda
Published on 2010-06-09T17:28:20Z
Indexed on
2010/06/09
17:32 UTC
Read the original article
Hit count: 1385
In the WIX setup I've got, when upgrading the application I have set a requirement to close down applications which might hold on to files which needs to be updated:
<util:CloseApplication
Id="CloseMyApp"
Target="[MyAppExe]"
CloseMessage="no"
Description="!(loc.MyAppStillRunning)"
RebootPrompt="no"
ElevatedCloseMessage="no"
/>
The application on the other hand will capture closing down the window with a "user friendly" dialog box where the user can confirm that he or she wants to close down the application.
I've experienced problems with the CloseApplication, and one theory is that the dialog box stops the application from closing.
So the question is: Could this be a possible problem? If so - how can I have this confirmation dialog box and still behave properly when the installer asks the application to close down? Must I listen to Win32 messages (such as WM_QUIT/WM_CLOSE) or is there a .NET API which I can use to respond properly to these events?
© Stack Overflow or respective owner