Omatase
18th May 2004 05:09 UTC
Ending the installer in a modern UI
This must be such an easy thing, but I can't find it in the help file or on this message board. Possibly because it's so easy noone has asked it :(.
Anyway, I am trying to:
1> show a welcome screen using the modern UI <--Working
2> Run a custom function on Welcome_leave <--Working
3> Close the installer<--Not working.
Using the Abort command only prevents the next window from displaying. This is good. I don't want the next window to display. I also want the installer to close though.
Anyway, now that I'm using the modern UI I seem to have no control over when to stop the installer. Can someone please tell me how I can close the installer when the user clicks 'Next'?
Thankyou for your help in advance.
Vytautas
18th May 2004 06:25 UTC
Have you tried the quit command?
Vytautas
Omatase
18th May 2004 13:34 UTC
No sir I had not, but as it happens that command also doesn't produce the desired result. Let me paste the relevant code in case that will be helpful. :winamp:
!define MUI_PAGE_CUSTOMFUNCTION_LEAVE "WelcomePageLeave"
!insertmacro MUI_PAGE_WELCOME
Function WelcomePageLeave
Call IsDotNETInstalled
Pop $R3
StrCmp $R3 0 +2
MessageBox MB_OK "Framework installed!" ID_OK Done
; else
MessageBox MB_OKCANCEL "The Microsoft .NET Framework is required for this application. Press OK to install, press Cancel to abort." IDOK InstallNET IDCANCEL 0
Abort ;<-Next page skipped
quit ;now how do I close the installer?
InstallNET:
SetOutPath "$INSTDIR"
SetOverwrite ifnewer
File "dotnetfx.exe"
ExecWait '"$INSTDIRdotnetfx.exe"'
Done:
FunctionEnd
Joost Verburg
18th May 2004 14:15 UTC
Remove the Abort command.
Omatase
18th May 2004 14:53 UTC
All worky! TYVM!!!