Archive: don't show page_Startmenu when specific section selected


don't show page_Startmenu when specific section selected
Hi,
in my MUI script the user can choose between 3 sections (A, B, C). The user can only select one of this (using Radio Button plugin).
One of this section ("C") does execute an external installer.

When the suer chooses "C", there is no need to show the MUI_PAGE_DIRECTORY and MUI_PAGE_STARTMENU, because everything is handled in the external installer and it's no use showing it. (In this case, all files are installed and handled by the external installer)

But how can I disable the two pages, when the user chose "C"?

thx for your help


i searched a little bit for answers and found a skipping tutorial, but it still doesn't work the way I need it

( http://nsis.sourceforge.net/Skipping_Pages )

I added the function:

Function dirPre
${If} ${SectionIsSelected} ${TheExternalInstallerSection}
abort
${EndIf}
FunctionEnd


and call this before the directory and start menu pages :
  !define MUI_PAGE_CUSTOMFUNCTION_PRE dirPre
!insertmacro MUI_PAGE_DIRECTORY

!define MUI_PAGE_CUSTOMFUNCTION_PRE dirPre
!insertmacro MUI_PAGE_STARTMENU Application $StartMenuFolder


The problem is now, that the external installer never gets executed. I have to embed the Installer.exe and wanted it to be stored in $temp

; ExternalInstallerSection

Section $(ExternalInstallerName) TheExternalInstallerSection
SetOutPath "$TEMP"
File "extInstaller\Installer.exe"
ExecWait '"$TEMP\extInstaller\Installer.exe" /NoMenuItems'

Delete "$TEMP\Installer.exe"

;BUG1 the installer is not deleted after installation
;BUG2 atm the exec command isn't executed when skipping directory and Start menu page

SectionEnd

Function .onGUIEnd
${If} ${SectionIsSelected} ${TheExternalInstallerSection}
Delete "$TEMP\Installer.exe"
${EndIf}
FunctionEnd


+ outputPath didn't match with the ExecWait
(in the section), that was maybe the problem that the exec wasn't called
(changed it several times and forgot to adjust the paths)

now everything is working, don't know if that's the quick'n'dirty version, but it works
;)