Old 30th December 2007, 19:20   #1
dllmain
Senior Member
 
dllmain's Avatar
 
Join Date: Sep 2005
Location: Berlin, Germany
Posts: 207
Need help with NSIS 2.34 warning

I get this warning from NSIS 2.34:

Quote:
Variable "mui.StartMenuPage.Create" not referenced or never set, wasting memory!
"StartMenuPage" is the page id I passed to MUI_PAGE_STARTMENU.

Any ideas what's wrong? Thanks in advance!
dllmain is offline   Reply With Quote
Old 30th December 2007, 20:10   #2
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
What script caused that?

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 30th December 2007, 22:59   #3
dllmain
Senior Member
 
dllmain's Avatar
 
Join Date: Sep 2005
Location: Berlin, Germany
Posts: 207
Quote:
Originally posted by kichik
What script caused that?
Here's a minimal example giving this and only this warning.

PHP Code:
OutFile not_referenced_case.exe

!include "MUI2.nsh"

var StartMenuFolder
!insertmacro MUI_PAGE_STARTMENU "StartMenuPage" $StartMenuFolder
!insertmacro MUI_PAGE_INSTFILES

!insertmacro MUI_LANGUAGE "English"

Section -dummy
SectionEnd 
Attached Files
File Type: nsi not_referenced_case.nsi (247 Bytes, 266 views)
dllmain is offline   Reply With Quote
Old 31st December 2007, 18:15   #4
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
Well, you don't use MUI_STARTMENU_WRITE_BEGIN, so it's a lacking script. But nonetheless, that warning could be avoided. Submit a bug report and I'll fix it for the next release.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 2nd January 2008, 03:48   #5
dllmain
Senior Member
 
dllmain's Avatar
 
Join Date: Sep 2005
Location: Berlin, Germany
Posts: 207
Quote:
Originally posted by kichik
Well, you don't use MUI_STARTMENU_WRITE_BEGIN, so it's a lacking script.
Interesting, never heard of that before. I found it saves me manually writing $StartMenuFolder to the registry. Does it do anything more? I didn't find any documentation about it.
Is there a similar way to write $INSTALLDIR to the registry automatically?

Quote:
Originally posted by kichik
But nonetheless, that warning could be avoided. Submit a bug report and I'll fix it for the next release.
Just opened a bug here:
http://sourceforge.net/tracker/index...49&atid=373085

Keep up the good work!
dllmain is offline   Reply With Quote
Old 2nd January 2008, 18:45   #6
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
It's documented under the MUI documentation. If you define MUI_STARTMENUPAGE_REGISTRY_ROOT, MUI_STARTMENUPAGE_REGISTRY_KEY and
MUI_STARTMENUPAGE_REGISTRY_VALUENAME it will also write the selected value to the specified registry key.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 3rd January 2008, 06:04   #7
dllmain
Senior Member
 
dllmain's Avatar
 
Join Date: Sep 2005
Location: Berlin, Germany
Posts: 207
Quote:
Originally posted by kichik
It's documented under the MUI documentation. If you define MUI_STARTMENUPAGE_REGISTRY_ROOT, MUI_STARTMENUPAGE_REGISTRY_KEY and
MUI_STARTMENUPAGE_REGISTRY_VALUENAME it will also write the selected value to the specified registry key.
Hm, I had that without MUI_STARTMENU_WRITE_BEGIN before and nothing was written to registry.


On $INSTDIR again: I have to manually write it to the registry?
dllmain is offline   Reply With Quote
Old 3rd January 2008, 18:48   #8
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
It'll be written and read for you, only if you use MUI_STARTMENU_WRITE_BEGIN and MUI_STARTMENU_WRITE_END.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik 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