View Full Version : Problem with InstallScript actions in a Suite project

08-05-2015, 06:29 AM
I'm having an issue running even the most simple InstallScript Suite actions in an Advanced UI/Suite project. Log shows the following when running the action:

8-5-2015[02:15:32 PM]: Running event 'Test'
8-5-2015[02:15:32 PM]: Launching InstallScript action in function 'Test'
8-5-2015[02:15:32 PM]: Engine: request for proxy handler, 0, 0
8-5-2015[02:15:33 PM]: Action returned value 0x80020005
8-5-2015[02:15:33 PM]: Action 'Test' returned status 0x80070643

That function consists of a single SuiteLogInfo call in a nearly-stock Setup.rul. There seems to be something off with this particular project as I had to specifically define paths to default InstallShield libraries to get it to even compile and a similar test function in a freshly created Suite project works fine. However, reconstructing the project from scratch will be quite a task, so any hints that could help with restoring the current project file into a usable state would be highly appreciated.

08-05-2015, 09:07 AM
What is the prototype for the script function you are attempting to call? Specifically, what is the parameter type? The error in the log (0x80020005) indicates a type mismatch, which can occur when attempting to call an exported script function that is prototyped incorrectly. A correct prototype would be:

export prototype ScriptFunctionName(OBJECT);

Note the function accepts one parameter which must be of type OBJECT.

08-06-2015, 05:02 AM
Thanks Josh, that was it :) I've written so much InstallScript custom actions for basic MSI projects that I had automatically set HWND as the parameter there and failed to spot that while wondering what's wrong.