[wix-users] How WixTools manage the upgrades?

Markus Kramer markuskramerigitt at gmail.com
Tue Aug 18 02:17:00 PDT 2020


Edwin,
thank you for the blog entry of 2010.
I found and now use the WIX_UPGRADE_DETECTED  condition which is set by the
MajorUpgrade element.

Thank you for pointing me to the schedule attribute of  MajorUpgrade, I was
not aware of it.

Best Regards,
Markus00


On Tue, Aug 18, 2020 at 2:50 AM Edwin Castro <egcastr at gmail.com> wrote:

> Markus,
>
> I use a variant of the approach described at
>
>
> https://code.dblock.org/2010/05/11/msi-property-patterns-upgrading-firstinstall-and-maintenance.html
>
>
> Note that's a pretty old post and some of the properties you'll need to
> reference have changed. There's a comment that gets you most of the way
> there.
>
> You can use the Schedule attribute on MajorUpgrade to control when
> RemoveExistingProducts is scheduled.
>
> https://wixtoolset.org/documentation/manual/v3/xsd/wix/majorupgrade.html
>
> https://wixtoolset.org/documentation/manual/v3/howtos/updates/major_upgrade.html
>
>
> I mostly use Schedule="afterInstallInitialize" but check the documentation
> so you select the option that makes the most sense for your product.
>
> --
> Edwin G. Castro
>
>
> On Mon, Aug 17, 2020 at 10:37 AM Markus Kramer <
> markuskramerigitt at gmail.com> wrote:
>
>> Edwin,
>> In an Major Upgrade, how do you specify the condition for a Custom Action
>> that shall only execute in an upgrade?
>>
>> I tried
>> *     Installed AND NOT REMOVE*
>> but in a Major Upgrade, the Custom Action was skipped (Condition not met).
>>
>> Also, how do you schedule  RemoveExistingProducts early?
>>
>> Best Regards,
>> Markus
>>
>> On Mon, Aug 17, 2020 at 4:58 PM Edwin Castro via wix-users <
>> wix-users at lists.wixtoolset.org> wrote:
>>
>>> Do you mean WiX Toolset when you say WixTools? If yes, then you are
>>> probably really asking how does the Windows Installer support upgrades?
>>> The
>>> WiX Toolset is a collection of tools for authoring Windows Installer
>>> packages.
>>>
>>> https://docs.microsoft.com/en-us/windows/win32/msi/patching-and-upgrades
>>>
>>> You'll see the answer is "it depends on how you author your MSI
>>> package". I
>>> understand that answer isn't very satisfying but it is a correct answer.
>>>
>>> I author my MSI packages to "uninstall the old version and install the
>>> new
>>> version" by using a Major Upgrade and schedule RemoveExistingProducts
>>> early.
>>>
>>> --
>>> Edwin G. Castro
>>>
>>> On Sun, Aug 16, 2020, 16:10 Davide Perini via wix-users <
>>> wix-users at lists.wixtoolset.org> wrote:
>>>
>>> > As title.
>>> > How WixTools manage the upgrades?
>>> >
>>> > Suppose that I have a version 1.0 installed,
>>> > what happen if I install version 1.1 on it?
>>> >
>>> > DOes it uninstall the old version and reinstall the new one?
>>> >
>>> > Thanks
>>> > Davide
>>> >
>>> > ____________________________________________________________________
>>> > 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