Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

UNinstall a second msi package


7 replies to this topic

Augusto

Augusto
  • Members
  • 32 posts

Posted 10 January 2002 - 15:46

Is this possible?:

UNinstall a second msi package during the execute secuence. I cannot use the upgrade table, since the package I want to uninstall, if present, is a beta version (Microsoft's stuff) without such code.

If it is possible, please help me out.

Thanks a lot,
Augusto


Kurt Schneider

Kurt Schneider
  • Members
  • 98 posts

Posted 10 January 2002 - 17:12

Augusto,

Sure it's possible.  I would use the RegLocator table to find the UninstallString for the .msi.  Typically they are found here:

HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\<Product Code>\

Then you would associate this value to a Property using the AppSearch table.  Once the registry value exists in a property you can create a Custom Action, type 34 I think, to launch an executable stored in the Directory table.  The Source would be the SystemFolder and the Target would be your property.  When I do this, I place the Custom Action in the Execute sequence after InstallValidate.

Have a Great Day!

Kurt Schneider


Augusto

Augusto
  • Members
  • 32 posts

Posted 11 January 2002 - 15:24

I had done it in a similar way, by running a CA launching an executable stored in a property  with value: msiexec.exe /x{product-code} /q.
With both methods I get the same error: 1722. Two msi packages cannot run simultaneously.
I am rather lost here :(



Kurt Schneider

Kurt Schneider
  • Members
  • 98 posts

Posted 11 January 2002 - 23:50

Augusto,

I apologize for the bad information.  I re-examined my installation that does something similar to this.  The one difference is that the application that I am uninstalling was created with InstallShield 6.0.  It is not WindowsInstaller based.  I get the same errors that you describe when I tried to uninstall an .MSI during the execute sequence.  Sorry about that!

:(

Kurt Schneider


Augusto

Augusto
  • Members
  • 32 posts

Posted 14 January 2002 - 10:36

I am sure there is got to be a way  to do it. It is a pretty normal thing to do during a typical installation.

Somebody out there must know! PLEASE, let us know!


pdriley

pdriley
  • Members
  • 91 posts

Posted 14 January 2002 - 18:17

I don't know whether this idea is acceptable, I can think of some reasons it might not be, but you do have the option of writing that uninstall string to

SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce

Scheduling a reboot at the end of the install will remove the product for you.

Another idea which might work, though I'm not entirely convinced, would be to run the Uninstall String in a CA after InstallFinalize (and not allowing the installer to wait for it to finish).

But are you sure you can't use the upgrade table?  I thought all MSI installers had an Upgrade Code.


Ramesh

Ramesh
  • Members
  • 2 posts

Posted 06 February 2002 - 01:23

You may want to try this : Create  a custom action type  39 (or 103 to ignore ruturn value) Use the product code of the install in the Source field and REMOVE="ALL"  in the target field. This will launch the nested uninstall without complaining about concurrent installs.

tl0

tl0
  • Members
  • 49 posts

Posted 04 February 2004 - 23:34

QUOTE (Ramesh @ 2002-02-06 00:23)
You may want to try this : Create a custom action type 39 (or 103 to ignore ruturn value) Use the product code of the install in the Source field and REMOVE="ALL" in the target field. This will launch the nested uninstall without complaining about concurrent installs.

is this in the UI sequence or the Execute sequence?