mindwarp
11th November 2009 18:30 UTC
MUI_FINISHPAGE_RUN_FUNCTION and MUI_FINISHPAGE_RUN, run doesn't ?
I've been adding some installer options, a couple of check boxes and I've added MUI_FINISHPAGE_RUN_FUNCTION, so I can process the check boxes and store info to a file.
However, now MUI_FINISHPAGE_RUN fails to launch my program via the check box.
Aren't both allowed ?
I've tried changing the order of those two lines, but it doesn't make a difference.
TIA
Anders
11th November 2009 20:30 UTC
MUI_FINISHPAGE_RUN_FUNCTION means you get full control, if you want to run something, use one of the exec instructions inside your run function
mindwarp
12th November 2009 10:32 UTC
Right, thanks.
Would I also have to create my own check box, to launch my program at the end of the setup.
Is there some example code to do this already?
mindwarp
12th November 2009 12:25 UTC
I've been searching the NSIS files...
Found these...
!ifdef MUI_FINISHPAGE_RUN
!insertmacro MUI_INSTALLOPTIONS_READ $MUI_TEMP1 "ioSpecial.ini" "Field 4" "State"
StrCmp $MUI_TEMP1 "1" 0 mui.finish_norun
!ifndef MUI_FINISHPAGE_RUN_FUNCTION
!ifndef MUI_FINISHPAGE_RUN_PARAMETERS
StrCpy $MUI_TEMP1 "$\"${MUI_FINISHPAGE_RUN}$\""
!else
StrCpy $MUI_TEMP1 "$\"${MUI_FINISHPAGE_RUN}$\" ${MUI_FINISHPAGE_RUN_PARAMETERS}"
!endif
Exec "$MUI_TEMP1"
!else
Call "${MUI_FINISHPAGE_RUN_FUNCTION}"
!endif
mui.finish_norun:
!endif
Could I just add this to my MUI_FINISHPAGE_RUN_FUNCTION function ?
mindwarp
12th November 2009 15:50 UTC
Nope doesn't work :(