简体   繁体   中英

Commiting .exe fails using Custom Action in Installer Project

I'm trying to create in VS17 Installer project a .MSI installer for a bunch of other .EXE files (an simple setup of other installers). The main idea is to use my project to install about 5 different programs, one after the other. I want to emphasize that the EXEs are not part of the solution (for instance, one of them is the installer of Notepad++ I downloaded from the internet).

I loaded all my .EXEs files to the Commit section of Custom actions. When my installer runs it sure position all .EXE files in the correct place, but when the first one is being lunched it's get to a point where I get the following message:

"Another installation is running"

(referring to my own installer). I have no choice but to close this window and leave the current installation, and then my own installer fails:

"..A program run as part of the setup did not finish as expected..."

The result is a kind of a deadlock... Eventually, I had to cancel and could't install anything.

I understand that Windows can't run more then one installer at the same time... What can I do to lunch all my .EXE file one by one AFTER my .MSI installer finishes?

I Found a suitable solution for me, The Windows installer won't run more then one inallation proccess at the same time, therefore what I did was:

Method A (fastest): I used a .vb file in the Commit section of Custom Actions, and used it to run my setups.

Method B (Better): Override the Commit method in the Install Class and invoke all my setups from there (via one batch file). To make it run post-install I had to set project's main output in ALL Custom Actions section (Install, Commit, Rollback and Uninstall - and NOT only at Commit section).

worked just Fine. In this scenario all the setups are running separately from main installation, therefore the main installer inform the user that installation was over, only then start all setups.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM