Old 15th May 2006, 13:42   #1
cobramanTW
Junior Member
 
Join Date: May 2006
Posts: 3
Sorting start menu after installation is completed.

Hi All

I add a folder named "SM_Folder" to start menu programs folder(SMPROGRAMS), where SM_Folder contains all my installed programs shortcut.

How NSIS to sort this "SM_Folder"(just this folder) after installation is completed.

Thx
cobramanTW is offline   Reply With Quote
Old 15th May 2006, 14:20   #2
Afrow UK
Moderator
 
Afrow UK's Avatar
 
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
In the Start menu list? Windows manages this.

-Stu
Afrow UK is offline   Reply With Quote
Old 15th May 2006, 15:56   #3
cobramanTW
Junior Member
 
Join Date: May 2006
Posts: 3
Thanks for your reply

I know it is managed by Windows and not NSIS ^_^

I post here because it is installation-related subject.

Maybe Shell API can do this because windows taskbar suppost this function ("sort by name").

Just discussion...
cobramanTW is offline   Reply With Quote
Old 16th May 2006, 06:13   #4
cobramanTW
Junior Member
 
Join Date: May 2006
Posts: 3
I think I found the answer !!

Delete corresponding key under
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\MenuOrder\Start Menu2\Programs

if existed before creating shortcut.

code:

!define SM_Folder "My Start menu shortcut folder"

..........
..........

Section "My software"

..........
..........

; delete this key before creating shortcut
DeleteRegKey HKCU "Software\Microsoft\Windows\CurrentVersion\Explorer\MenuOrder\Start Menu2\Programs\${SM_Folder}"

; create shortcut now
CreateDirectory "$SMPROGRAMS\${SM_Folder}"
CreateShortCut "$SMPROGRAMS\${SM_Folder}\App1.lnk" "$INSTDIR\App1.exe"
CreateShortCut "$SMPROGRAMS\${SM_Folder}\App2.lnk" "$INSTDIR\App2.exe"

..........
..........

SectionEnd

cobramanTW is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump