cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
kberthelot
Level 3

Executing logic after custom dialog

I have a custom dialog that prompts the user to enter two text values, which I'm storing in the registry. For one of the values, I need to perform a transformation on the value before storing it. I've tried creating a custom action that calls the installscript code that performs the transformation, but I can't seem to get the code to execute. I've tried placing the custom action at different places in the install sequence with no luck. At best nothing happens, at worst the install crashes. I stripped out all the logic in the function and just displayed a dialog to see whether the function was being invoked and it's not.

Is there a "best practice" for doing this sort of thing? I get the impression that creating custom actions is typically viewed as a last resort. If a custom action is indeed the right approach, what's the best way to invoke it?
Labels (1)
0 Kudos
(3) Replies
heiner_violet
Level 7

I'm using Custom Actions in Basic-MSI projects very often - and see no problems.
Is it necessary to execute your installscript code during the install sequence? Otherwise you could try to execute the custom action immediately after the dialogs Next-Button (accessible via the behaviour tab of the dialog).
0 Kudos
kberthelot
Level 3

Yeah, I tried doing that too, but apparently I'm missing something since the action never gets executed. Here's the installscript code I'm trying to execute, and I've attached images showing how the custom action and dialog are configured:



export prototype void doDialog();

function void doDialog()
begin
MessageBox("Hello", INFORMATION);
end;
0 Kudos
kberthelot
Level 3

I figured it out. I was not including the handle to the installer database as an input parameter to my function.
0 Kudos