cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
sammathew
Level 4

Uninstalling Previous Product

Hi All,

I am using InstallShield 2008 which is a pure InstallScript project.I have created a product1 using InstallShield 2008 in a 32 bit machine.I have installed the product1 in the 64 bit target machine.

I have created a nother product2 with the same InstallShield 2008 in 32 bit machine and now i want to uninstall the older product1 when i try to install the new product2.

I hope there is a way to handle this.Can any one help me how to do this plz.

My advance thanks !
Labels (1)
0 Kudos
(3) Replies
retzcat
Level 6

There is a way--- what we do is define the uninstall string
#define UNINSTALL_PATH "software\\microsoft\\windows\\currentversion\\uninstall"

//Set the registry root directory
nremove12 = FALSE;

nremove12 = PerformUnistall("JRE 1.2", UNINSTALL_PATH+"\\JRE 1.2",
"-y -a -m -f\""+PROGRAMFILES+"\\javasoft\\jre\\1.2\\Uninst.isu\"",
WINDIR+"Isuninst.exe");


This has worked real well for us... Create a function for this and call it in OnFirstUIBefore()...

Hope this helps
0 Kudos
sammathew
Level 4

Hi retzcat,

Thanks for your reply,

My product code for product1 and product2 are different so will it work fine still?

And can you tell is there any common path(for both 32 and 64 bit) to Query from the registry if the product is installed in 32 bit as well in 64 bit machine.

Plz help me.

My advance Thanks!
0 Kudos
retzcat
Level 6

You could always look for the GUID's...

PerformUnistall("App Name",UNINSTALL_PATH+"\\{GUID}",
"\""+COMMONFILES^"\\INSTAL~1\\PROFES~1\\RunTime\\0701\\Intel32\\Ctor.dll\",LaunchSetup \""+PROGRAMFILES+"InstallShield Installation Information\\{GUID}\\setup.exe\" -uninst", WINSYSDIR^"rundll32");

IF you would like the PerformUninstall function, e-mail me and I can send it to you..
Retzcat
sammathew wrote:
Hi retzcat,

Thanks for your reply,

My product code for product1 and product2 are different so will it work fine still?

And can you tell is there any common path(for both 32 and 64 bit) to Query from the registry if the product is installed in 32 bit as well in 64 bit machine.

Plz help me.

My advance Thanks!
0 Kudos