Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Replacing Non-versioned Files User Data with companion files

66 views
Skip to first unread message

Dominique

unread,
Jul 7, 2003, 12:23:27 PM7/7/03
to
The companion file works well on 2000, ME, and XP. We have been
installing our products with no problem since.

I am getting into a new setup for a new product and I was wondering if
there is any new documentation out here for MSI Windows Installer?

I am referring to something else beside the Msi.Chm.

Thanks god for this forum and members...

===========================
Previous Post:

From: Dominique (dgsc...@ingr.com)
Subject: Replacing Non-versioned Files - User Data
Newsgroups: microsoft.public.platformsdk.msi
Date: 2002-05-20 10:23:44 PST

During Installation I want to replace a file (marked for installation)
that already exists with the same name in the target folder even
though it has a newer date than the one I deliver (Modified date is
later than the Create date).

I want to force the replacement of the file in question no matter
what.

It is a Sample MDB file that we deliver. If the user modifies it, the
date of the Sample MDB changes and then the file does not get replaced
anymore.

How can I replace every time that MDB with the MDB on the delivery CD?

Thank you

D.G.

Message 2 in thread
From: Scott Williams (thunde...@diespam.yahoo.com)
Subject: Re: Replacing Non-versioned Files - User Data
Newsgroups: microsoft.public.platformsdk.msi
Date: 2002-05-20 11:31:14 PST

The easiest way would be to remove the file first. This can be done a
couple of different ways. You could author a CustomAction that would
just
delete it, or author the RemoveFile table that will be excuted when
the
RemoveFiles action is encountered in the Install Sequence. Obviously
RemoveFiles would have to happen before InstallFiles.

Also, if you author your installs to use the UpgradeTable and set it
up in
such a way that you remove the older products before you install your
newer
MSI file, that would accomplish the same thing.


Message 3 in thread
From: Phil Wilson (phil....@nospam.unisys.com)
Subject: Re: Replacing Non-versioned Files - User Data
Newsgroups: microsoft.public.platformsdk.msi
Date: 2002-05-20 11:39:57 PST

Is this the first install, and if not, what kind of update are you
doing?
The way to replace the existing file is different depending on whether
you're installing for the first time, doing a minor upgrade using
REINSTALLMODE or a major upgrade using the upgrade table.

Message 4 in thread
From: Curtis Sawin (curti...@comcast.net)
Subject: Re: Replacing Non-versioned Files - User Data
Newsgroups: microsoft.public.platformsdk.msi
Date: 2002-05-20 11:42:12 PST

Two options. Set the "a" attribute in the REINSTALLMODE property or
use
companion files. In this scenario, I strongly recommend to use
companion
files. Check out the SDK document "Companion Files" for details how
to
implement this.

When installing non-versioned files, MSI does not consider the time
stamp of
the file being installed. MSI only looks to see if the existing file
has
been modified, by comparing the create date and modified date of the
existing file.

This is a significant change from the "latest date wins" rule commonly
used
by most legacy installations.

Hope this helps!

Curtis Sawin

Message 5 in thread
From: Naren Salem (naren...@ni.com)
Subject: Re: Replacing Non-versioned Files - User Data
Newsgroups: microsoft.public.platformsdk.msi
Date: 2002-05-21 15:23:09 PST

In this case you should use another versioned file in your installer
as a
companion file. Since your versioned file will overwrite a lower
version
file from the previous version of your product, the data file will
also get
installed.
Here is a link to the documentation on companion files.
http://msdn.microsoft.com/library/en-us/msi/over_1jg3.asp?frame=true

Naren

0 new messages