Calling Included files in ScriptPackager MSI

This forum can be browsed by the general public. Posting is limited to current SAPIEN license holders with active maintenance and does not offer a response time guarantee.
Forum rules
DO NOT POST LICENSE NUMBERS, ACTIVATION KEYS OR ANY OTHER LICENSING INFORMATION IN THIS FORUM.
Only the original author and our tech personnel can reply to a topic that is created in this forum. If you find a topic that relates to an issue you are having, please create a new topic and reference the other in your post.

Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
This topic is 3 years and 1 week old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.
User avatar
jml143
Posts: 2
Last visit: Sun Feb 04, 2024 7:09 am

Calling Included files in ScriptPackager MSI

Post by jml143 »

Hi,

I have a script that I want to deploy as an MSI (created with script packager). That MSI will also have 2 files: 1 cfg file and one EXE utility file included in the MSI project. I intend to create a custom action in my packaged script that will call the EXE file during installation.

My problem is that I don't know how to create the custom action that will call the EXE. During the MSI installation process, the EXE will probably be extracted to a "cryptic" path in a temp folder somewhere on the PC. How can I make sure that the custom action (and the main packaged script) will be able to find the EXE wherever it is extracted on the PC.

Thanks!
User avatar
Alexander Riedel
Posts: 8473
Last visit: Tue Mar 19, 2024 1:15 am
Answers: 19
Been upvoted: 37 times

Re: Calling Included files in ScriptPackager MSI

Post by Alexander Riedel »

If you install the exe with your MSI containing your script, the .cfg and .exe, it will all be in the same folder, designated as INSTALLDIR.
Please see https://www.sapien.com/blog/2018/02/26/ ... i-builder/
The important part for executing any file in a custom action that is installed and not pre-existing, is to select 'deferred' as execution time,
as this happens after files are copied and before the installation is completed.
Alexander Riedel
SAPIEN Technologies, Inc.
This topic is 3 years and 1 week old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.