|
|
#1 |
|
Junior Member
Join Date: May 2006
Posts: 4
|
Inserting additional pages
Your help is needed to guide on how to insert additional pages into this system generated script as all efforts to do so did not yield the desired results.
I want to insert the serial number page just after the welcome page. the serial key is defined as below ## Displays the serial dialog Function SerialPageShow !insertmacro MUI_HEADER_TEXT "Enter Serial Code" "Enter the software serial code to continue." PassDialog: ialog Serial \/HEADINGTEXT 'Please enter the serial code located on the software CD case...' \ /CENTER \ /BOXDASH 92 70 3 '' \ /BOXDASH 172 70 3 '' \ /BOX 252 70 3 '' Pop $R0 # success, back, cancel or error FunctionEnd ## Validate serial numbers Function SerialPageLeave ## Pop values from stack Pop $R0 Pop $R1 Pop $R2 ;Pop $R3 ;Pop $R4 ## A bit of validation StrCmp $R0 '421' +3 MessageBox MB_OK|MB_ICONEXCLAMATION "Wrong input!" Abort StrCmp $R1 '890' +3 MessageBox MB_OK|MB_ICONEXCLAMATION "Wrong input!" Abort StrCmp $R2 '576' +3 MessageBox MB_OK|MB_ICONEXCLAMATION "Wrong input!" Abort ## Display the values MessageBox MB_OK|MB_ICONINFORMATION "Authorised to install this application" FunctionEnd ;//////////////////////////////////////// this is the main code ; Welcome page !insertmacro MUI_PAGE_WELCOME ; License page !insertmacro MUI_PAGE_LICENSE "userLicence.rtf" ; Components page !insertmacro MUI_PAGE_COMPONENTS ; Directory page !insertmacro MUI_PAGE_DIRECTORY ; Start menu page var ICONS_GROUP !define MUI_STARTMENUPAGE_NODISABLE !define MUI_STARTMENUPAGE_DEFAULTFOLDER "HICA" !define MUI_STARTMENUPAGE_REGISTRY_ROOT "${PRODUCT_UNINST_ROOT_KEY}" !define MUI_STARTMENUPAGE_REGISTRY_KEY "${PRODUCT_UNINST_KEY}" !define MUI_STARTMENUPAGE_REGISTRY_VALUENAME "${PRODUCT_STARTMENU_REGVAL}" !insertmacro MUI_PAGE_STARTMENU Application $ICONS_GROUP ; Instfiles page !insertmacro MUI_PAGE_INSTFILES ; Finish page !define MUI_FINISHPAGE_RUN "$INSTDIR\HICA.exe" !define MUI_FINISHPAGE_SHOWREADME "$INSTDIR\README.txt" !insertmacro MUI_PAGE_FINISH ; Uninstaller pages !insertmacro MUI_UNPAGE_INSTFILES ; Language files !insertmacro MUI_LANGUAGE "English" ; MUI end ------ ;///////////////////////////////////////////////////// thanks upfront |
|
|
|
|
|
#2 |
|
Major Dude
Join Date: May 2005
Location: New Zealand
Posts: 916
|
Put this command after the '!insertmacro MUI_PAGE_WELCOME' command:
code: "Only a MouseHelmet will save you from a MouseTrap" -Jason Ross (Me) NSIS 3 POSIX Ninja Wiki Profile |
|
|
|
![]() |
|
|||||||
| Thread Tools | Search this Thread |
| Display Modes | |
|
|