Home All Groups Group Topic Archive Search About

How to update an application

Author
13 Apr 2005 6:56 AM
Li Pang
Hi,

I deployed an application by a MSI file. After a while the application was
modified. For updating it I wrote another MSI and deploy it again. However,
if I changed the productcode, the application can be installed but there were
two links in the Add/Romove Programs panel. If I didn't change the
productcode, the deployment stopped by an alert message saying to remove the
previous version.

What I want to know is how to easily update the application bu using a MSI
which overrides the previous version, and keeps only one link in the
Add/Remove Program.

Thanks in advance

Author
13 Apr 2005 8:50 AM
Philip Hristov
Hello,

You have to uninstall the previous version first before installing the
new one, you can't just overwrite the previous version like the other
install engines do (NSIS for example).

Do this:

In the setup project properties of your setup project, set the Remove
Previous Version to TRUE, and increment the version. Then you will be
asked to change the product and package codes, change them. Build the
the msi file and it will first check for previous version and such
version is present - it will uninstall it, and then it will install the
new one.

Greetings,

Philip.
Author
13 Apr 2005 9:14 AM
Li Pang
Hi Philip Hristov,

Thanks for your response. I did already exactly what you suggested. The
problem is that there will be two links in the Add/Remove Programs panel,
each link is related to different version. It seems that disinstallation of
the previous version couldn't remove its link in Add/Remove Program panel.

Show quoteHide quote
"Philip Hristov" wrote:

> Hello,
>
> You have to uninstall the previous version first before installing the
> new one, you can't just overwrite the previous version like the other
> install engines do (NSIS for example).
>
> Do this:
>
> In the setup project properties of your setup project, set the Remove
> Previous Version to TRUE, and increment the version. Then you will be
> asked to change the product and package codes, change them. Build the
> the msi file and it will first check for previous version and such
> version is present - it will uninstall it, and then it will install the
> new one.
>
> Greetings,
>
> Philip.
>
>
Author
13 Apr 2005 9:27 AM
Li Pang
Hi Philip,

Thanks for your response. I did already what you suggested. However, there
is problem that there will be two links in the Add/Remove Programs panel
after install the new MSI. It seems that the disinstallation of previous
version couldn't remove its link.


Show quoteHide quote
"Philip Hristov" wrote:

> Hello,
>
> You have to uninstall the previous version first before installing the
> new one, you can't just overwrite the previous version like the other
> install engines do (NSIS for example).
>
> Do this:
>
> In the setup project properties of your setup project, set the Remove
> Previous Version to TRUE, and increment the version. Then you will be
> asked to change the product and package codes, change them. Build the
> the msi file and it will first check for previous version and such
> version is present - it will uninstall it, and then it will install the
> new one.
>
> Greetings,
>
> Philip.
>
>
Author
13 Apr 2005 11:44 AM
Philip Hristov
Li,

It should not be like that. It is the same as you uninstall the
software manually. Maybe something is messed with your system or you
miss something in the setup project? But when you start the package
with the new version, it uninstalls the previous version, right? Only
the Add/Remove Programs entry exists?

Best,

Philip.
Author
13 Apr 2005 11:50 AM
Crouchie1998
If you set remove previous version to true then it doesn't seem to work in
my past experiences. I personally think this is a bug. Although the VS.IDE
overwrites the previous installation with a newer version.

Crouchie1998
BA (HONS) MCP MCSE
Official Microsoft Beta Tester
Author
13 Apr 2005 12:29 PM
Li Pang
I have the same felling as Crouchie has. BTW, I used VS 2002 to make MSI. I
don't know VS 2003 fixes this problem.

Show quoteHide quote
"Philip Hristov" wrote:

> Li,
>
> It should not be like that. It is the same as you uninstall the
> software manually. Maybe something is messed with your system or you
> miss something in the setup project? But when you start the package
> with the new version, it uninstalls the previous version, right? Only
> the Add/Remove Programs entry exists?
>
> Best,
>
> Philip.
>
>
Author
13 Apr 2005 3:12 PM
Philip Hristov
I have not tried this with VS 2002, I have 2003 installed here and I
prefer InstallShield when it comes to creating a setup.

Regards,

Philip
Author
14 Apr 2005 6:17 AM
Li Pang
Hi,

My college just find a way to fugure this problem:
change the version number, don't change package code but change only
productcode, and set DetectNewerVersion to true.

Show quoteHide quote
"Philip Hristov" wrote:

> I have not tried this with VS 2002, I have 2003 installed here and I
> prefer InstallShield when it comes to creating a setup.
>
> Regards,
>
> Philip
>
>
Author
14 Apr 2005 3:53 PM
Li Pang
It works only for install/reinstall MSI for "onlyme option". In order to work
for "everyone", the MSI must be edited by ORCA and setting "ALLUSERS" value.

Show quoteHide quote
"Li Pang" wrote:

> Hi,
>
> My college just find a way to fugure this problem:
> change the version number, don't change package code but change only
> productcode, and set DetectNewerVersion to true.
>
> "Philip Hristov" wrote:
>
> > I have not tried this with VS 2002, I have 2003 installed here and I
> > prefer InstallShield when it comes to creating a setup.
> >
> > Regards,
> >
> > Philip
> >
> >