We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

Bannor
Posts: 1
Joined: Tue Apr 08, 2014 3:03 pm

Overwriting Files from Exe to MSI Install

Hi, first post!

I am trying to make an EXE to MSI install and it all works fine, no problem when I run it.

However, in the exe is a CAB file that holds a couple of legacy files that I need to overwrite when installing. I have tried editing the cab file, but the exe fails, so I have to use the original cab files with the legacy files in it ans let them be installed. I need some advice on how I can overwrite/replace files when its installed from the exe but before the installer closes.

Is there a simple way of doing this?

Thanks for any help.
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: Overwriting Files from Exe to MSI Install

Hi and welcome to Advanced Installer forums.

Thank you for your interest in Advanced Installer.

In order to achieve what you want you can use the following approach:
- create a new simple MSI package that contains only the files that you want to overwrite
- select all the files, right-click on them and select "Properties", then go to the "Operations" tab and select the "Always overwrite existing file" option
- in that MSI, create also a search to find the path where your EXE package was installed (usually the applications write their installation paths in the registry), rename the search (i.e. EXE_PATH)
- in the Install Parameters page, use the property of the search as the installation path for your MSI, in the "Application Folder" field (i.e. [EXE_PATH])
- add the created MSI as a post-install prerequisite in the Prerequisites page of the "EXE to MSI" project, but after the EXE package that already exist there
- build and run the project

In the case described above, your MSI will search for the install location of the EXE package and will install its file to the same location overwriting the files already available to that location.

Let us know if this helped, otherwise give us more details about your scenario.

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”