Old 19th June 2009, 17:51   #1
o_owd
Senior Member
 
o_owd's Avatar
 
Join Date: Feb 2003
Location: TGM, Romania
Posts: 176
Send a message via ICQ to o_owd Send a message via Yahoo to o_owd
silent install / multilanguage

Hello,

I have to add silent install support to one of our intallers.
Our installer has multi language support.
How can I choose the language to install during a silent install ?
Maybe with an answer file ? But how ? The languages have IDs or should I check the name of the language ?

Thanks.
o_owd is offline   Reply With Quote
Old 20th June 2009, 15:36   #2
Afrow UK
Moderator
 
Afrow UK's Avatar
 
Join Date: Nov 2002
Location: Surrey, England
Posts: 8,434
I don't think NSIS has a built in command line switch for specifying the language but it is straight forward to add one using GetParameters followed by GetOptions. For example:

code:

${If} ${Silent}
${GetParameters} $R0
${GetOptions} $R0 `/lang=` $LANGUAGE
${Else}
.. display language selection
${EndIf}



If you don't want to specify locale id's you could specify language names (i.e. /lang=English) and you'd then need to:
code:

${GetParameters} $R0
${GetOptions} $R0 `/lang=` $R0
${If} $R0 == `English`
StrCpy $LANGUAGE ${LANG_ENGLISH}
${ElseIf} $R0 == ...
...
${EndIf}



Stu
Afrow UK is offline   Reply With Quote
Old 20th June 2009, 16:29   #3
o_owd
Senior Member
 
o_owd's Avatar
 
Join Date: Feb 2003
Location: TGM, Romania
Posts: 176
Send a message via ICQ to o_owd Send a message via Yahoo to o_owd
Thanks,
I will try it.
o_owd 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