It's difficult to know what to advise.The upgrade method that Visual Studio
provides is the RemovePreviousVersions project property. This and other
settings cause a new version to uninstall the prior version and then install
the new version. So what was installed by the older version will be
uninstalled, including files that may have been updated by the user. Ideally
this is something you take into account when you design your first version.
For minor changes to an installed product, people often build patch files,
msp files, and these obey the file overwrite rules you want.
Or if you're going to be installing exactly the same files in your new
version, you can do what's called a minor upgrade by reinstalling the
product. Build the new MSI file, a new version, the same productcode, and
then install it with:
msiexec /i <new msi file> REINSTALL=ALL REINSTALLMODE=vomus.
Another general technique is for the new version to locate and copy the
updated files that you want to preserve, but this requires a custom action,
and Visual Studio's custom actions are sequenced so that they are called
after the old product is removed, so that won't work.
--
Phil Wilson
[MVP Windows Installer]
Definitive Guide to Windows Installer
http://www.amazon.com/exec/obidos/tg/detail/-/1590592972/104-7044380-4696760 [quoted text, click to view] "manpreet" <manpreetsingh@abosoftware.com> wrote in message
news:e6ZgQJfpEHA.3856@TK2MSFTNGP10.phx.gbl...
> Yes , I am talking about the file that previous version of setup has
> installed and user has updated it.
> Say a lower version version of setup has installed a particluar file. The
> user may or may not have updated it. Now if the user installs a
> Upgrade(Higher) version on already installed lower version of setup, the
> upgrade setup should not copy that file if exists in the destination
> location. How to achieve it?
>
> Also, how can i make certain files not to be removed from the system after
> uninstallation ?
>
> Regards,
> Manpreet Singh
>
> "Phil Wilson" <pdjwilson@nospam.cox.net> wrote in message
> news:ui8sEUQpEHA.556@tk2msftngp13.phx.gbl...
>> If you're talking about the RemovePreviousVersions project property, this
>> works by uninstalling the old version and then re-installing the new
>> version, so you're not overwriting anything anyway. What kind of files
>> are
>> you talking about? Data files that the user may have updated?
>> --
>> Phil Wilson
>> [MVP Windows Installer]
>> Definitive Guide to Windows Installer
>>
>
http://www.amazon.com/exec/obidos/tg/detail/-/1590592972/104-7044380-4696760 >>
>> "manpreet" <manpreetsingh@abosoftware.com> wrote in message
>> news:ufzVInJpEHA.132@TK2MSFTNGP14.phx.gbl...
>> > Hi,
>> >
>> > I need certain files not to be overwriten during installation in
> upgrade
>> > version of already installed setup. How to acheive the above tasks t in
> VS
>> > .Net Setup Project?
>> >
>> > Any other suggestion in this regard are most welcome.
>> >
>> > Regards,
>> > Manpreet Singh
>> >
>> >
>>
>>
>
>