This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- Re: Basic MSI project - custom action - execute from path - does this work ?
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jul 08, 2015
08:41 AM
Basic MSI project - custom action - execute from path - does this work ?
Hi,
I am new to InstallShield and am struggling massively with the quality of documentation, so am hoping that I can find help within this forum.
I have created a Basic MSI project.
I can happily manage to get applications installed, along with .Net as a prerequisite.
I have tried to call an external executable using a custom action that is triggered after "InstallFinalize", however, no matter what I try, it fails with error 1721.
I have now tried to simply run the "dir" command and redirect to a file... this gives the same error.
Could somebody please tell me if I am misunderstanding what this custom action is able / supposed to do and whether I am doing something stupid, and if so, what I should actually do to achieve this.
Snippet from Log output.....
Action ended 14:22:50: InstallFinalize. Return value 1.
MSI (s) (48:F0) [14:22:50:705]: Doing action: MY_executeFromPath
Action 14:22:50: MY_executeFromPath.
Action start 14:22:50: MY_executeFromPath.
MSI (s) (48:F0) [14:22:50:709]: Note: 1: 1721 2: MY_executeFromPath 3: C:\Users\Public\AppData\Local\Temp\ 4: "dir > 123.txt"
Error 1721. There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor. Action: MY_executeFromPath, location: C:\Users\Public\AppData\Local\Temp\, command: "dir > 123.txt"
MSI (s) (48:F0) [14:22:56:691]: Product: IRIS 2015 -- Error 1721. There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor. Action: MY_executeFromPath, location: C:\Users\Public\AppData\Local\Temp\, command: "dir > 123.txt"
Action ended 14:22:56: MY_executeFromPath. Return value 3.
Action ended 14:22:56: INSTALL. Return value 3.
Many thanks
mark
I am new to InstallShield and am struggling massively with the quality of documentation, so am hoping that I can find help within this forum.
I have created a Basic MSI project.
I can happily manage to get applications installed, along with .Net as a prerequisite.
I have tried to call an external executable using a custom action that is triggered after "InstallFinalize", however, no matter what I try, it fails with error 1721.
I have now tried to simply run the "dir" command and redirect to a file... this gives the same error.
Could somebody please tell me if I am misunderstanding what this custom action is able / supposed to do and whether I am doing something stupid, and if so, what I should actually do to achieve this.
Snippet from Log output.....
Action ended 14:22:50: InstallFinalize. Return value 1.
MSI (s) (48:F0) [14:22:50:705]: Doing action: MY_executeFromPath
Action 14:22:50: MY_executeFromPath.
Action start 14:22:50: MY_executeFromPath.
MSI (s) (48:F0) [14:22:50:709]: Note: 1: 1721 2: MY_executeFromPath 3: C:\Users\Public\AppData\Local\Temp\ 4: "dir > 123.txt"
Error 1721. There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor. Action: MY_executeFromPath, location: C:\Users\Public\AppData\Local\Temp\, command: "dir > 123.txt"
MSI (s) (48:F0) [14:22:56:691]: Product: IRIS 2015 -- Error 1721. There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor. Action: MY_executeFromPath, location: C:\Users\Public\AppData\Local\Temp\, command: "dir > 123.txt"
Action ended 14:22:56: MY_executeFromPath. Return value 3.
Action ended 14:22:56: INSTALL. Return value 3.
Many thanks
mark
(3) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jul 08, 2015
09:34 AM
There are differences between what you can run at a command prompt, and what you can run through the API CreateProcess. Custom actions in Windows Installer use the latter, and it doesn't support redirection or the commands built into cmd.exe (like dir) that are not executables. Sometimes you can call cmd.exe to do your dirty work, for example, set up your package to run: [SystemFolder]cmd.exe /c "dir > 123.txt"
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jul 09, 2015
09:51 AM
Hi Michael,
Thanks for your reply.
To give you a bit of background. I initially tried installing SQL express 2014 via the Redistributable view. This went through the process of extracting & installing but ultimately failed with
"The installation of Microsoft SQL Server 2014 Express RTM (x64) appears to have failed."
So I tried to run the SQL install via the custom action, giving "Error 1721. There is a problem with this Windows Installer package. A program required for this install to complete could not be run."
This is frustrating as if I amend my custom action, replacing "[INSTALLDIR]SQLEXPR_x64_ENU.exe" with "[INSTALLDIR]myTest.exe" , everything works without fault.
I have even tried extracting from SQLEXPR_x64_ENU.exe and running the setup.exe directly "[INSTALLDIR]SQLEXPR_x64_ENU\setup.exe" but this too fails.
Is there anyway I can get this to work ?
Thanks.
mark
Thanks for your reply.
To give you a bit of background. I initially tried installing SQL express 2014 via the Redistributable view. This went through the process of extracting & installing but ultimately failed with
"The installation of Microsoft SQL Server 2014 Express RTM (x64) appears to have failed."
So I tried to run the SQL install via the custom action, giving "Error 1721. There is a problem with this Windows Installer package. A program required for this install to complete could not be run."
This is frustrating as if I amend my custom action, replacing "[INSTALLDIR]SQLEXPR_x64_ENU.exe" with "[INSTALLDIR]myTest.exe" , everything works without fault.
I have even tried extracting from SQLEXPR_x64_ENU.exe and running the setup.exe directly "[INSTALLDIR]SQLEXPR_x64_ENU\setup.exe" but this too fails.
Is there anyway I can get this to work ?
Thanks.
mark
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jul 09, 2015
07:16 PM
Regarding to the failure of the Microsoft SQL Server 2014 Express prerequisite installation, have you checked out this thread? Also if you are installing a named instance besides the default instance; SQLEXPRESS, make sure that you have updated the prerequisite's condition as to detect the named instance that you are trying to install. The built-in Microsoft SQL Server 2014 Express prerequisites are designed to install the default instance and check for the following registry key to detect the product:
If the registry key does not exist after the Microsoft SQL Server 2014 Express setup completed, the prerequisite thinks it failed to install.
I hope that helps.
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\SQLEXPRESS\MSSQLServer\CurrentVersion
If the registry key does not exist after the Microsoft SQL Server 2014 Express setup completed, the prerequisite thinks it failed to install.
I hope that helps.