Prev Previous Post   Next Post Next
Old 27th June 2003, 00:49   #1
Lilla
Junior Member
 
Join Date: Jun 2003
Posts: 46
What field to check in my StartMenuLeave function?

MUI 1.65, I updated via CVS this morning. Win98SE here.

I am using the logic of the StartMenu.nsi and I build on that.
My StartMenuLeave function is shown below.

My problem is that I don't know where to find the folder name entered (or selected) by the user. MUI_STARTMENUPAGE_VARIABLE contains the previous value entered (or selected) by the user.

This is my first Leave function, and I cannot find the answer.

; validate the Start Menu folder entered (or selected) by the user
Function StartMenuLeave
MessageBox MB_OK "at1 MUI_STARTMENUPAGE_VARIABLE = ${MUI_STARTMENUPAGE_VARIABLE}" ;debug

StrCmp ${MUI_STARTMENUPAGE_VARIABLE} "${MUI_PRODUCT}" PathGood
StrCmp ${MUI_STARTMENUPAGE_VARIABLE} "" PathBad

Push ${MUI_STARTMENUPAGE_VARIABLE}
Call GetFileName ; get last part of path
Pop $R0 ;$R0 is now "last part of path"
StrCmp $R0 "${MUI_PRODUCT}" PathGood
PathBad:
MessageBox MB_OK|MB_ICONSTOP "Problem with folder name. The Start Menu folder (or sub-folder) must be ${MUI_PRODUCT}"
Abort ; stay on page
PathGood:
FunctionEnd

Thank you,
Lilla
Lilla is offline   Reply With Quote
 
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