[wix-users] Replacing newer files

Walter Dexter wfdexter at gmail.com
Fri Jun 10 11:16:01 PDT 2016


Be warned that you can really, really mess up your installed result with
"amus."

It tells Windows Installer "I don't care what you think, just install
this." Windows Installer is actually pretty smart and will usually do the
right thing.

I would look at the RemoveFile solution again. You may need to tweak order,
or may have messed up your components, becasue it should work. Do a
detailed log (/l*v or /l*xv) and try to figure out why it isn't replacing
the others. It'll be in there.

In my (far from expert) opinion, only use "amus" if you have a controlled
environment (like you're creating installers for internal use and you have
control over when it's run or not run.)

I'm still recovering from our deployment team sending out version 1.1 with
REINSTALLMODE="amus" and installing on top of version 1.2.

They did it to 14,000 systems that are scattered all over the US. The thing
that seems to fix it the easiest is to install version 1.3.




On Fri, Jun 10, 2016 at 6:22 AM, Winter,Stijn S. de <
stijn.dewinter at student.fontys.nl> wrote:

> This works like I wanted, thanks
>
> Kind regards,
> Stijn de Winter
> ________________________________________
> Van: wix-users <wix-users-bounces at lists.wixtoolset.org> namens James
> Buchan <James.Buchan at servelec-synergy.com>
> Verzonden: vrijdag 10 juni 2016 12:26
> Aan: WiX Toolset Users Mailing List
> Onderwerp: Re: [wix-users] Replacing newer files
>
> This should do the trick:
> <Property Id="REINSTALLMODE" Value="amus"/>
>
> But please be sure that you understand what it will do (and if/how it will
> impact your users).
>
> https://msdn.microsoft.com/en-us/library/windows/desktop/aa371182(v=vs.85).aspx
>
>
> James Buchan
> Development Engineer
>
> -----Original Message-----
> From: wix-users [mailto:wix-users-bounces at lists.wixtoolset.org] On Behalf
> Of Winter,Stijn S. de
> Sent: 10 June 2016 10:56
> To: WiX Toolset Users Mailing List <wix-users at lists.wixtoolset.org>
> Subject: Re: [wix-users] Replacing newer files
>
> Okay i tried this.
>
> But i encountered a problem:
> When running the MSI which replaces the files ONLY older files will be
> replaced.
> I made the same MSI but this time it did not replace the files, instead it
> only removed it. Same code for removal!
> This way all files are removed.
>
> This is ofcourse not the way I want it. Ideas?
>
> Kind regards,
> Stijn de Winter
> ________________________________________
> Van: wix-users <wix-users-bounces at lists.wixtoolset.org> namens Phill
> Hogland <phill.hogland at rimage.com>
> Verzonden: dinsdag 7 juni 2016 15:00
> Aan: WiX Toolset Users Mailing List
> Onderwerp: Re: [wix-users] Replacing newer files
>
> First it would be good to clarify that this is not a wix behavior but
> defined behavior of MSI.
>
> https://msdn.microsoft.com/en-us/library/windows/desktop/aa368599(v=vs.85).aspx
>
> There may be other approaches to this issue depending on your exact
> requirements, but when I need to 'always overwrite' a file I use the
> following pattern:
>
>       <Component Id="someid" Directory="myDir" >
>         <!-- Always Overwrite pattern, otherwise file copy is skipped for
> unversioned-modified file. . -->
>         <RemoveFile Id="remove_fileid" Name="file.ext" On="install" />
>         <File Id="fileid" Source="!(bindpath.name)\file.ext" />
>       </Component>
>
> I do this rarely, but I do have a scenario where this pattern is used.
> ________________________________________
> From: wix-users <wix-users-bounces at lists.wixtoolset.org> on behalf of
> Winter,Stijn S. de <stijn.dewinter at student.fontys.nl>
> Sent: Tuesday, June 7, 2016 7:10:00 AM
> To: WiX Toolset Users Mailing List
> Subject: [wix-users] Replacing newer files
>
> Hello All,
>
>
> My installer has to replace some files, some files are newer than the one
> it will be replaced with.
>
> WiX seems to refuse to do this. Can I force WiX to overwrite existing
> files?
>
>
> Kind regards,
>
> Stijn de Winter
>
>
> ==========================================================
> Op deze e-mail zijn de volgende voorwaarden van toepassing:
> http://www.fontys.nl/disclaimer
> The above disclaimer applies to this e-mail message.
>
> ____________________________________________________________________
> WiX Toolset Users Mailing List provided by FireGiant
> http://www.firegiant.com/
>
> ____________________________________________________________________
> WiX Toolset Users Mailing List provided by FireGiant
> http://www.firegiant.com/
>
> ____________________________________________________________________
> WiX Toolset Users Mailing List provided by FireGiant
> http://www.firegiant.com/
>
> ____________________________________________________________________
> WiX Toolset Users Mailing List provided by FireGiant
> http://www.firegiant.com/
>
> ____________________________________________________________________
> WiX Toolset Users Mailing List provided by FireGiant
> http://www.firegiant.com/
>


More information about the wix-users mailing list