Old 30th June 2006, 01:45   #1
00zero
Junior Member
 
Join Date: May 2006
Location: pittsburgh
Posts: 7
im stumped any help would be appreciated

I have been trying to get this to work all day and i keep getting this error

Quote:
!insertmacro: MUI_INSTALLOPTIONS_READ
Usage: ReadINIStr $(user_var: output) ini_file section entry_name
Error in macro MUI_INSTALLOPTIONS_READ on macroline 5
on the last line of code

Quote:
;**********************************************************
;Mathematica Directory Page
!define MathDir
ReserveFile "MathLocal.ini"
LangString MATHLOCAL_TITLE ${LANG_ENGLISH} "Please enter the loaction of Mathematica"
LangString MATHLOCAL_SUBTITLE ${LANG_ENGLISH} " "
Page custom mathpage
;********************************************************

;**********************************************************
;runs the function needed for the custom page
Function .onint
!insertmacro MUI_INSTALLOPTIONS_EXTRACT_AS "mathlocal.ini" "MathLocal"
FunctionEnd

;gets values of the custom page
Function mathpage

!insertmacro MUI_HEADER_TEXT "$(MATHLOCAL_TITLE)" "$(MATHLOCAL_SUBTITLE)"

;displays the custom page
!insertmacro MUI_INSTALLOPTIONS_DISPLAY "MathLocal"

;gets the user entered values
!insertmacro MUI_INSTALLOPTIONS_READ $MathDir "MathLocal" "Field 1" "State"

FuncitonEnd
;**********************************************************

i can figure it out i have read all the help and example files and been at it all day. any help would be much appreciated

thanks
jonathan
00zero is offline   Reply With Quote
Old 30th June 2006, 07:52   #2
1123581321
Junior Member
 
Join Date: Jun 2006
Location: Beijing CN/Houston TX
Posts: 5
Send a message via AIM to 1123581321
I'd help but I'm new myself and don't use MUI
1123581321 is offline   Reply With Quote
Old 30th June 2006, 09:25   #3
galil
Member
 
Join Date: Jan 2003
Posts: 83
For starters, change "!define MathDir" to "Var MathDir",
because it appears that's what you want it for. You try to use it as variable, but ealier in your code just defined an empty string with it (which you'd have to use as ${MathDir}).
galil is offline   Reply With Quote
Old 30th June 2006, 10:46   #4
Filus
Junior Member
 
Join Date: Feb 2006
Location: Pomerania
Posts: 16
Re: im stumped any help would be appreciated

It's better if you read from page after displaying it in seperate "leave" function:

code:

;**********************************************************
;Mathematica Directory Page
Var MathDir

...

Page custom mathpage_show mathpage_leave
;********************************************************

;**********************************************************
;runs the function needed for the custom page

...

;shows custom page
Function mathpage_show

!insertmacro MUI_HEADER_TEXT "$(MATHLOCAL_TITLE)" "$(MATHLOCAL_SUBTITLE)"
;displays the custom page
!insertmacro MUI_INSTALLOPTIONS_DISPLAY "MathLocal"

FuncitonEnd

;gets the user entered values
Function mathpage_leave

!insertmacro MUI_INSTALLOPTIONS_READ $MathDir "MathLocal" "Field 1" "State"
FunctionEnd
;**********************************************************

Filus 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