The issue is as follows:

I've made an exe-file that uninstalls several programs if they exist on the computer.
Then it installs a new version from an msi-file in the same location.

My problem is that I would like this to be done in a new msi-file..

I would like my Install.msi to include my file script.exe and newclient.msi
Then I would like Install.msi to extract these files to a temporary location, run the script.exe which starts newclient.msi-installation.
Install.msi should then delete these extracted files as they are no longer needed.

Any tips on how to do it?

I'm using Wise Package Studio for repacking, and my experience is quite limited.
0 Comments   [ - ] Hide Comments


Please log in to comment

Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
Answer this question or Comment on this question for clarity


Either MSI or WSE can help to complete this task ...

Using MSI :

1. Add the files into MSI with temp directory as InstallDIR
2. Create a Custom action to Uninstall the previous application tha tis run the script.exe
3. Create a Custom action to Install the Current application.
4. Create a custom action to delete files
5. Systemcomponent =1 - optional

Using WSE :

1.Set Temp location
2. Install File action to install the files into temp location.
3. Execute Program action to run the script.exe.(wait for exit)
4. Execute Program action to Run Newclient.msi.(wait for exit)
5. Execute program action using cmd you can delete the temp folder.(wait for exit).

You can go through custom action guide present online for help on custom actions.
Answered 02/15/2012 by: mahendraKumar
Senior Yellow Belt

Please log in to comment
I wouldn't be encouraging anybody to use WSE (WiseScript) since Wise is dead in the water. Yes, Flexera have said they'll support in some future release but WSE was already in a backwater during Symantec's ownership.

@OP: Often, people forget that you can capture uninstallations as well as installations so I suggest doing that. Use NotePad or CMD.EXE as a "dummy" installer for SetupCapture to run. When it's ready, uninstall your apps, then close NotePad/CMD.EXE. You'll end up with a bunch of entries in the RemoveFile and RemoveRegistry tables (after all, applications consist of just files and registry entries). You need to be aware of possible unregistering of files which remain on the system, which you'll obviously need to remove from your capture.

You can then paste the content of both tables to your MSI.
Answered 02/15/2012 by: VBScab
Red Belt

Please log in to comment
How will caption of uninstallation work?
I've got 3 different clients that I have to uninstall.

The oldest one is not automaticaly updated when installing the newest one.
The newest one uninstalls the second oldest one.

My environment has computers with all combinations of the three clients.. So I need to uninstall all of these if they exist.
This is what my Exe-file does.

How do I use CustomAction? I'm really new to this..

I do know the uninstallation-string for all of these clients, and I know how to detect if they exist.
Answered 02/15/2012 by: Kennethj
Senior Yellow Belt

Please log in to comment
How will caption of uninstallation work? Exactly as I described. The mix of versions in your estate doesn't really matter since, as I said, the installation is simply a collection of files and registry data.

Before you do anything else, though, find the free download of Phil Wilson's The Definitive Guide To Windows Installer. This will be a major uphill struggle unless you know the fundamentals.
Answered 02/15/2012 by: VBScab
Red Belt

Please log in to comment
I understand that I can capture an uninstall (and I actually have used it several times)
The issue here is that I have to uninstall several programs if they exist on the computer, and then install a new one.
The old versions can not be installed on the computer at the same time.
How do I capture several uninstalls so the computer does all of them before installing the new one?

Personally I'm very happy with my solution so far, but as I said, I'm struggling with the creation of a MSI to do the job..
Answered 02/15/2012 by: Kennethj
Senior Yellow Belt

Please log in to comment