Archive: Cannot get CheckBox to appear


Cannot get CheckBox to appear
I am trying to create a simple installer and on the finishpage I want to have 3 checkboxes:

1 for running the app after the install
1 for creating a Desktop shortcut
1 for creating a QuickLaunch shortcut

I am using MUI_FINISHPAGE_RUN for running the app, and MUI_FINISHPAGE_SHOWREADME for creating the Desktop shortcut. Those both work fine. However, I am having a tough time getting the QuickLaunch checkbox to show. Here are the functions I am using, which were obtained from another thread on here:


!define MUI_PAGE_CUSTOMFUNCTION_PRE QL_PRE
!define MUI_PAGE_CUSTOMFUNCTION_SHOW QL_SHOW
!define MUI_PAGE_CUSTOMFUNCTION_LEAVE QL_LEAVE

Function QL_PRE
ReadINIStr $0 "$PLUGINSDIR\iospecial.ini" "Field 6" "HWND"
SetCtlColors $0 0x000000 0xFFFFFF
FunctionEnd

Function QL_SHOW
WriteINIStr "$PLUGINSDIR\iospecial.ini" "Settings" "NumFields" "8"
WriteINIStr "$PLUGINSDIR\iospecial.ini" "Field 6" "Type" "CheckBox"
WriteINIStr "$PLUGINSDIR\iospecial.ini" "Field 6" "Text" "&Create Quicklaunch Shortcut"
WriteINIStr "$PLUGINSDIR\iospecial.ini" "Field 6" "Left" "120"
WriteINIStr "$PLUGINSDIR\iospecial.ini" "Field 6" "Right" "315"
WriteINIStr "$PLUGINSDIR\iospecial.ini" "Field 6" "Top" "130"
WriteINIStr "$PLUGINSDIR\iospecial.ini" "Field 6" "Bottom" "140"
WriteINIStr "$PLUGINSDIR\iospecial.ini" "Field 6" "State" "1"
FunctionEnd

Function QL_LEAVE
ReadINIStr $0 "$PLUGINSDIR\iospecial.ini" "Field 6" "State"
StrCmp $0 "0" end
SetOutPath "$INSTDIR"
CreateShortCut "$QUICKLAUNCH\$(^Name).lnk" "$INSTDIR\Launch jEdit.exe"
end:
FunctionEnd


I checked the IOSpecial.INI while it is running and the entry for the CheckBox (Field 6) does appear, but it never shows up in the installer.

EDIT: Also, the QuickLaunch shortcut IS made during the install. It appears after clicking the "Next" button on the welcome screen.

Any help with this would be much appreciated. Thanks.

Quick update:

I re-made my installer script and curiously the CheckBox entry in the iospecial.ini for the QuickLaunch appears once on the finishpage, but the checkbox still doesn't show.

Here is a screenshot of iospecial.ini opened in the HM NIS InstallOptions Editor (while installer is running on finishpage)
http://img.photobucket.com/albums/v2...ptionsview.png

And here is a screenshot of how it looks while running
http://img.photobucket.com/albums/v2...actualview.png


You should add the creation of the checkbox into the pre function and the control colors thing into the show function.


Damn it. It works perfectly now. Thank you!