Issues related to creating Shortcuts in the Start Menu
Purpose of my Installer is:
1) Create a folder by name PosPlus (default c:\PosPlus)
2) Create a sub-folder by name 'samples' in c:\posPlus
This 'samples' sub-folder contains a few application related text files.
These text files are also copied in this sub-folder.
3) Copy/extract pos.exe to c:\PosPlus
4) Copy/extract databack.exe to c:\PosPlus
5) Copy/extract uninst.exe to c:\PosPlus
6) Copy/extract PosPlus.chm to c:\PosPlus
7) Create desktop shortcut for main application:pos.exe
8) Create shortcut in Windows Start Menu->Program->
in following order:
Start Menu-->Program-->Pos Plus-->Pos Plus
-->Backup Manager
-->Pos Manual
-->Samples
-->Uninstall

My problem is that the installer is smoothly installing all the steps mentioned-above,
but the shortcuts in the start menu for Pos Plus are not comming as per my above order.
The 'Uninstall' shortcut is comming as the first option and the others are also not in
the same order as shown above.

One more thing I want to do is that I want to show my sub-folder Samples and its contents in
this start menu. For this I added this line my script :

CreateDirectory "$SMPROGRAMS\PosPlus\Samples"

This helped me in showing the folder "Samples"(empty). Yes it is showing 'empty' although
it contains many text files inside it.

What I want :

Start Menu-->Program-->Pos Plus-->Pos Plus
-->Backup Manager
-->Pos Manual
-->Samples---->t1.txt(shortcut)
---->t2.txt(shortcut)
--->....... and so on when the user clicks samples
and when he clicks t1.txt then that file opens
up in notepad.
-->Uninstall

A fraction of script is given below to understand my issue:

Section "Complete" SEC01
SetOutPath "$INSTDIR"
SetOverwrite ifnewer
File "AppFolder\pos.exe"
CreateDirectory "$SMPROGRAMS\PosPlus"
CreateDirectory "$SMPROGRAMS\PosPlus\Samples"
;CreateShortCut "$SMPROGRAMS\PosPlus\Samples" "$INSTDIR\Samples"
CreateShortCut "$SMPROGRAMS\PosPlus\Pos Plus .lnk" "$INSTDIR\pos.exe"
CreateShortCut "$SMPROGRAMS\PosPlus\Backup Manager.lnk" "$INSTDIR\databack.exe"
CreateShortCut "$DESKTOP\Pos Plus.lnk" "$INSTDIR\pos.exe"
File "AppFolder\databack.exe"
File "AppFolder\Format.txt"
File "AppFolder\PosPlus.chm"
CreateShortCut "$SMPROGRAMS\PosPlus\Pos Manual.lnk" "$INSTDIR\PosPlus.chm"
SetOutPath "$INSTDIR\Samples"
SetOverwrite try
File "AppFolder\Samples\T1.TXT"
File "AppFolder\Samples\T2.TXT"
File "AppFolder\Samples\T5.TXT"
File "AppFolder\Samples\T7.TXT"
File "AppFolder\Samples\T8.TXT"
File "AppFolder\Samples\T9.TXT"
File "AppFolder\Samples\T10.TXT"
File "AppFolder\Samples\T11.TXT"
File "AppFolder\Samples\T12.TXT"
File "AppFolder\Samples\T13.TXT"
File "AppFolder\Samples\T17.TXT"
File "AppFolder\Samples\T18.TXT"
File "AppFolder\Samples\T19.TXT"
File "AppFolder\Samples\T20.TXT"
File "AppFolder\Samples\Format.TXT"
SectionEnd

Section -AdditionalIcons
;WriteIniStr "$INSTDIR\${PRODUCT_NAME}.url" "InternetShortcut" "URL" "${PRODUCT_WEB_SITE}"
;CreateShortCut "$SMPROGRAMS\PosPlus\Website.lnk" "$INSTDIR\${PRODUCT_NAME}.url"
CreateShortCut "$SMPROGRAMS\PosPlus\Uninstall.lnk" "$INSTDIR\uninst.exe"
SectionEnd

Section -Post
WriteUninstaller "$INSTDIR\uninst.exe"
WriteRegStr HKLM "${PRODUCT_DIR_REGKEY}" "" "$INSTDIR\PosPlus.exe"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayName" "$(^Name)"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "UninstallString" "$INSTDIR\uninst.exe"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayIcon" "$INSTDIR\PosPlus.exe"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayVersion" "${PRODUCT_VERSION}"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "URLInfoAbout" "${PRODUCT_WEB_SITE}"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "Publisher" "${PRODUCT_PUBLISHER}"
SectionEnd



With regards,
Swapan Das