- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- Re: Custom Powershell action always fails
- 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
InstallShield 2015 Premier - AdminStudio Edition Version 22 Service Pack 1
Window 10
I created a ps1 script and tested it. Works fine. Modifies a json file.
Followed the instructions here: https://helpnet.flexerasoftware.com/installshield19helplib/helplibrary/CAPowerShell.htm
set the script as an installed file. Tuned on Bypass. Setup Search for Powershell.
I run the install, the files get copied, the ps1 is there, but the install always fails.
MSI (s) (64:F0) [08:52:30:527]: PROPERTY CHANGE: Deleting UpdateStarted property. Its current value is '1'. Action ended 8:52:30: InstallFinalize. Return value 1. MSI (s) (64:F0) [08:52:30:527]: Doing action: UpdateChromePrefs Action 8:52:30: UpdateChromePrefs. Action start 8:52:30: UpdateChromePrefs. MSI (s) (64:44) [08:52:30:527]: Invoking remote custom action. DLL: C:\WINDOWS\Installer\MSI401D.tmp, Entrypoint: m1 MSI (s) (64:88) [08:52:30:527]: Generating random cookie. MSI (s) (64:88) [08:52:30:543]: Created Custom Action Server with PID 2632 (0xA48). MSI (s) (64:1C) [08:52:30:605]: Running as a service. MSI (s) (64:1C) [08:52:30:621]: Hello, I'm your 64bit Impersonated custom action server. InstallShield: Attempting to load through CLR 4 APIs... InstallShield: Getting meta host... InstallShield: Enumerating available runtimes... InstallShield: Highest available runtime: v4.0.30319 InstallShield: Trying to use highest runtime... InstallShield: Using highest version runtime... InstallShield: Could not create Powershell script fileupdatechromeprefs: Resource 4096.0 was not found CustomAction UpdateChromePrefs returned actual error code 1603 (note this may not be 100% accurate if translation happened inside sandbox) Action ended 8:52:30: UpdateChromePrefs. Return value 3. Action ended 8:52:30: INSTALL. Return value 3.
Can anyone tell me what this error means?
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Can you please tell us the custom action sequence? Since the script file is the one to be installed, custom action execution has to be set as deferred execution.
Below link can tell you in detail about deferred execution :
https://helpnet.flexerasoftware.com/isxhelp22/helplibrary/ActionExecutionOptions.htm?
Can you give a try with that?
Thanks,
Jenifer
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Can you please tell us the custom action sequence? Since the script file is the one to be installed, custom action execution has to be set as deferred execution.
Below link can tell you in detail about deferred execution :
https://helpnet.flexerasoftware.com/isxhelp22/helplibrary/ActionExecutionOptions.htm?
Can you give a try with that?
Thanks,
Jenifer
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Thanks for the quick response!
Its set to immediate execution, and AfterInstallFinalize. So the file doesn't exist yet when it tries to execute it, so that's why its failing. Maybe some additional documentation on PowerShell using installed file would help future developers.
I ended up switching to Binary and that seems to have solved the problem.
![](/skins/images/8CE4FAD0DE6F3A6F9D0567434D2D2DAE/responsive_peak/images/icon_anonymous_message.png)