Let me correct something a bit:

If not add "<DialogRef Id="FilesInUse" />" line, the installation is okay but 
it won't detect and show "FilesInUse" dialog.
If add "<DialogRef Id="FilesInUse" />" line in code, the installation is okay 
if this is a fresh intallation(fresh means no previous version installed). 
If add "<DialogRef Id="FilesInUse" />" line in code, and there is the old 
version application running, then the installation of the new version will 
detect and show the "FilesInUse" dialog which is good. But later on the 
installation of the new version will be failed because of an Error called 2753. 
Why this happens? How to resolve it?

Thanks.



________________________________
From: little.forest <little.for...@ymail.com>
To: wix-users@lists.sourceforge.net
Sent: Friday, October 2, 2009 11:17:01 AM
Subject: [WiX-users] How to add FilesInUse support

We use WiX 3.0.

We have a problem: the end user is running the old version of the application, 
but she tries to install the new version at the same time. As we use major 
upgrade, the old version will be uninstalled first. So in this case, if the old 
version is running, we can't install the new version properly.

I knew "util:CloseApplication". So I tried that. But in our application, there 
is a requirement "close application will just minimize the GUI to system tray 
just like Yahoo Messenger". I'm not sure if "util:CloseApplication" does send 
WM_CLOSE message to our application. But even if it does, our application will 
just minimize itself to system tray but not close itself. We already tested it. 
The application didn't shut down. So we can't use this "util:CloseApplication".

Then I tried another solution: 
http://n2.nabble.com/Custom-action-sequencing-problem-td709311.html#a709311 
Well, it partly worked. If we keep the old version running, then the process is 
killed when installing the new version. However, just a few seconds later, the 
installation failed because of "Error code 2753". I realized the old version 
was uninstalled, the new version wasn't installed. Also, I was thinking killing 
a process directly might not be a good thing. So I kept searching other 
solutions.

Then I found someone said "FilesInUse". I think this solution even works for 
us. So I added this line:
<UI>
<DialogRef Id="FilesInUse" />
...
</UI>

Now we have new problem "Error code 2753". I tried two cases: 
Case 1: I kept the old version running, and I installed the new version. During 
installation, the "FilesInUse" dialog did show up - I was very happy. Then I 
exited the old version. The installation kept going.. just a few seconds, it 
failed. I noticed the old version was uninstalled, but the new version wasn't 
installed. Here is the log:
MSI (s) (48:4C) [10:15:34:839]: Note: 1: 2753 2: MainApp 
MSI (s) (48:4C) [10:15:34:839]: Note: 1: 2205 2:  3: Error 
MSI (s) (48:4C) [10:15:34:839]: Note: 1: 2228 2:  3: Error 4: SELECT `Message` 
FROM `Error` WHERE `Error` = 2753 
DEBUG: Error 2753:  The File 'MainApp' is not marked for installation.
The installer has encountered an unexpected error installing this package. This 
may indicate a problem with this package. The error code is 2753. The arguments 
are: MainApp, , 
MSI (s) (48:4C) [10:15:44:245]: Note: 1: 2205 2:  3: Error 
MSI (s) (48:4C) [10:15:44:245]: Note: 1: 2228 2:  3: Error 4: SELECT `Message` 
FROM `Error` WHERE `Error` = 1709 
MSI (s) (48:4C) [10:15:44:245]: Product: BigAppleProduct -- The installer has 
encountered an unexpected error installing this package. This may indicate a 
problem with this package. The error code is 2753. The arguments are: MainApp, 
, 
The log says error, but what the error means? What caused this error? The log 
didn't say.

Case 2: do a fresh installation. There is no "FilesInUse" dialog showing up, of 
course. But the install still failed - Error 2753. This doesn't make any sense. 

It seems the problem is this new added line "<DialogRef Id="FilesInUse" />". By 
adding this line, the error 2753 is introduced. Why is that? So how can I add 
this FilesInUse support in WiX 3? Where I did wrong here? 

Many many thanks.
/Brian


      __________________________________________________________________
Looking for the perfect gift? Give the gift of Flickr! 

http://www.flickr.com/gift/
------------------------------------------------------------------------------
Come build with us! The BlackBerry&reg; Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9-12, 2009. Register now!
http://p.sf.net/sfu/devconf
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users



      __________________________________________________________________
The new Internet Explorer® 8 - Faster, safer, easier.  Optimized for Yahoo!  
Get it Now for Free! at http://downloads.yahoo.com/ca/internetexplorer/
------------------------------------------------------------------------------
Come build with us! The BlackBerry&reg; Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9&#45;12, 2009. Register now&#33;
http://p.sf.net/sfu/devconf
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to