Archive: Problem with ButtonEvent Plugin


Problem with ButtonEvent Plugin
I have been using the ButtonEvent plugin for quite a while now, mostly to add buttons to the components page. However, when I tried to add a button to the parent dialog, everything worked ok except that the "Abort" statement didn't seem to do anything. It performed the code but then skipped to the next page disregarding the Abort statement. Is there something wrong from my end or is this a bug?


anyone ?


If you have a button on the parent dialog, you need to call your button code in all Leave functions for all installer dialogs. The plugin example shows this.

-Stu


Afrow UK, I did as you said and all the custom pages seem to be working fine but in the Components page, the Abort statement is still not being executed. The same thing is happening with your example file.

The button is loaded in the MUI_CUSTOMFUNCTION_GUIINIT function. Here's the code from the Leave function of the Components page:


ButtonEvent::WhichButtonID /NOUNLOAD
Pop $R1

${If} $R1 = 69
ExecShell open http://www.blah.com
Abort
${ElseIf} ...

Thanks, fixed.
http://nsis.sf.net/File:ButtonEvent.zip

-Stu


Super. Thanks alot =)


Just make sure you disable the parent window button on the InstFiles page. I've added code to the example.

-Stu