Adding a Custom Action that executes an MSP - Advanced Installer Community

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!

treeves
Posts: 4
Joined: Wed Apr 04, 2012 5:30 pm

Adding a Custom Action that executes an MSP

I have a package where I need to add a custom action to install an MSP. Advanced Installer has options for everything but this. (msi, vbs, , dll, js, exe) Please advise on how to do this or is this a possibility for a new feature?

Thanks


Forgot to mention that this would be from the Temporary folder.
Bogdan
Posts: 2796
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: Adding a Custom Action that executes an MSP

Hi and welcome to our forums,

You can launch an MSP package through a "Launch File or Open URL" custom action with sequence. If the MSP package is added as a temporary file then the file is copied on the target machine after the "Wizard Dialogs Stage -> Paths Resolution -> MigrateFeatureStates" standard action and removed after "Install Execution Stage -> Finish Execution". Therefore, your custom action should be scheduled under "Wizard Dialogs Stage -> Paths Resolution -> MigrateFeatureStates" standard action.

Please keep in mind that this approach it works only when the MSP package applies over an existing installation package on the target machine. If you want to execute the MSP for your current installation package then this approach doesn't work.

Let us know if this helps, otherwise please give us more details about what do you want to know.

Regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
treeves
Posts: 4
Joined: Wed Apr 04, 2012 5:30 pm

Re: Adding a Custom Action that executes an MSP

I want to execute the MSP for the current installation package. Is there any solution for this or is this something to look for in another release??
Bogdan
Posts: 2796
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: Adding a Custom Action that executes an MSP

Deploying a patch for the main package is quite an uncommon scenario, not practical at all and also not recommended. You could simply give to the users the latest version, i.e. the upgrade image. Is there a reason why you want to install them separately?

Regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
treeves
Posts: 4
Joined: Wed Apr 04, 2012 5:30 pm

Re: Adding a Custom Action that executes an MSP

I will clarify....
I have an Msi and an Msp, I am using advanced installer to create a wrapper msi, I need to install the wrapped MSI( am using a custom action) and the wrapped Msp(want to do this using a custom action).
Bogdan
Posts: 2796
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: Adding a Custom Action that executes an MSP

I assume the MSI you are installing using an UI custom action? Have you tried using the same type of custom action, scheduled just after the one installing the MSI, to install the patch?

Please note that the order is essential, and also the custom actions should be set to synchronous execution, to wait one after the other.

Regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
treeves
Posts: 4
Joined: Wed Apr 04, 2012 5:30 pm

Re: Adding a Custom Action that executes an MSP

Ordering is not an issue...
The Issue is I can not sellect anything other than (msi, dll, vbs, js , exe). If I select MSI again it does not recognize the MSP. So how am I to do this using a custom action?
Bogdan
Posts: 2796
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: Adding a Custom Action that executes an MSP

You can use our predefined custom action "Launch File or Open URL". Please note that our docs specify that the MSI custom actions are obsolete and should not be used anymore.

For the predefined custom action "Launch File or Open URL" you simply need to put this in the "Command" field:
- for the MSI

Code: Select all

msiexec /i "[&TempFileReference]"
-for the MSP

Code: Select all

msiexec.exe /update "[&TempFileReference]"
Where "[&TempFileReference]" is a formatted reference for your MSI/MSP temp files which Advanced Installer will generate when you are using the "Edit" button from the same field.

Regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”