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!

maulik291
Posts: 4
Joined: Thu Nov 17, 2016 7:27 am

Per-user and Per-machine installation in single MSI

Hello,

I want to create MSI with per-user bases to install my main application per-user bases without administrator authentication.
For this main application I required two prerequisites which are based on per-machine.
1) Framework
2) Per-machine installer

I have follow below mention steps to fulfill my requirements.
1) Created EXE project for per-machine installer in which i set prerequisites for the framework. Framework should be install silent.
1.1) Added custom action at last in "Wizard dialogs stage" to remove old installer of per-machine.
1.2) Set "Run as Administrator" in Install Parameters page for single admin authentication. Admin authentication required two time, at the time of old uninstall and second at new installation.
2) Created MSI project for per-user installer in which i set prerequisites as a feature-based for the per-machine EXE. Feature-based EXE should be install silent.
2.2) I have set install command "/q" in feature-based prerequisites to silent installation of per-machine installer.

Question
1) Custom action of per-machine installer not working in silent mode? If i remove "/q" install command and execute per-machine installer with UI then its works.
2) What are the steps to fulfill my requirement? All installation done through one MSI without any other dialogs.
3) Is there any another way to fulfill my requirement?

Thanks
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: Per-user and Per-machine installation in single MSI

Hi,
1) Custom action of per-machine installer not working in silent mode? If i remove "/q" install command and execute per-machine installer with UI then its works.
This happens because your custom action is placed on "Wizard Dialogs Stage, however, when a package is installed in silent mode that section is skipped, only the action from the "Install Execution Stage" section are executed.
2) What are the steps to fulfill my requirement? All installation done through one MSI without any other dialogs.
To install more packages from a single MSI, you can use the "Prerequisites" page support, then send the appropriate command lines to those prerequisites.

However, I'm afraid that a per-machine prerequisite cannot be installed silently from a per-user package that runs without administrator rights. So, the main package that installs the silent per-machine prerequisites should have administrator rights in order to pass those rights to the silent prerequisite.
3) Is there any another way to fulfill my requirement?
In order to achieve what you want, you can create a new project, check the "Run as administrator" option for it in the "Install Parameters" page, then add the "Framework", "Per-machine installer" and your "Per-user installer" as a prerequisite in that project.

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

Return to “Building Installers”