Winamp & Shoutcast Forums

Winamp & Shoutcast Forums (http://forums.winamp.com/index.php)
-   NSIS Discussion (http://forums.winamp.com/forumdisplay.php?f=65)
-   -   LicenseLangString in Modern UI (http://forums.winamp.com/showthread.php?t=249604)

robertpnl 25th June 2006 13:00

LicenseLangString in Modern UI
 
Hi,

I'm trying to create a install script with multi-language and with the modern UI. During installation, the page of EULA must be displayed. This works, but...

By starting installation, the user can select one of the available languages (Dutch or English). After then, when the EULA displays, only the Dutch EULA is showing. If the user choose English, also then the Dutch EULA is displayed.

During compiling I've got two warnings:
2 warnings:
LicenseLangString "lics" set multiple times for 0,
wasting space (..:43)
LangString "lics" is not set in language table of
language Dutch

A piece of code:

code:

; Modern UI
!include "MUI.nsh"

; LicenseLang
LicenseLangString lics $(LANG_ENGLISH) "English.rtf"
LicenseLangString lics $(LANG_DUTCH) "Dutch.rtf"

; Screens
!insertmacro MUI_PAGE_WELCOME
!insertmacro MUI_PAGE_LICENSE $(lics)
!insertmacro MUI_PAGE_DIRECTORY
!insertmacro MUI_PAGE_INSTFILES

; Uninstall screen
!insertmacro MUI_UNPAGE_WELCOME
!insertmacro MUI_UNPAGE_CONFIRM
!insertmacro MUI_UNPAGE_INSTFILES

; Language
!insertmacro MUI_LANGUAGE "English"
!insertmacro MUI_LANGUAGE "Dutch"



I don't get it why I got the two warnings and only the Dutch RTF is showing. Can someone please help me?

Greets
Robert-Paul

Joost Verburg 25th June 2006 13:41

Add these strings after inserting the language files.

robertpnl 25th June 2006 14:05

Quote:

Originally posted by Joost Verburg
Add these strings after inserting the language files.
Hi Joost,

Thank you for your reply, but it doesn't help.

Here the whole script (excep the sections):

code:

; Modern UI
!include "MUI.nsh"

Name "Test_ML 1.0"
OutFile "Setup.exe"
InstallDir "$PROGRAMFILES\Test\"
!define MUI_ABORTWARNING

; Language Selection Dialog Settings
!define MUI_LANGDLL_REGISTRY_ROOT "HKCU"
!define MUI_LANGDLL_REGISTRY_KEY "Software\Modern UI Test"
!define MUI_LANGDLL_REGISTRY_VALUENAME "Installer Language"

; Screens
!insertmacro MUI_PAGE_WELCOME
!insertmacro MUI_PAGE_LICENSE $(MUILicense)
!insertmacro MUI_PAGE_DIRECTORY
!insertmacro MUI_PAGE_INSTFILES

; Uninstall screen
!insertmacro MUI_UNPAGE_WELCOME
!insertmacro MUI_UNPAGE_CONFIRM
!insertmacro MUI_UNPAGE_INSTFILES

; Language
!insertmacro MUI_LANGUAGE "English"
!insertmacro MUI_LANGUAGE "Dutch"

; LicenseLang
LicenseLangString $(MUILicense) $(LANG_ENGLISH) "English.rtf"
LicenseLangString $(MUILicense) $(LANG_DUTCH) "Nederlands.rtf"

!insertmacro MUI_RESERVEFILE_LANGDLL

Function .onInit
!insertmacro MUI_LANGDLL_DISPLAY
FunctionEnd

Section ""
...
SectionEnd

Section "Uninstall"
...
SectionEnd

Function un.onInit
!insertmacro MUI_UNGETLANGUAGE
FunctionEnd



I don't get it. What is wrong? The both .nlf are in de same directory.

Thanks
Robert-Paul

Afrow UK 25th June 2006 14:16

LicenseLangString $(MUILicense) $(LANG_ENGLISH) "English.rtf"
LicenseLangString $(MUILicense) $(LANG_DUTCH) "Nederlands.rtf"

should be

LicenseLangString MUILicense $(LANG_ENGLISH) "English.rtf"
LicenseLangString MUILicense $(LANG_DUTCH) "Nederlands.rtf"

No parenthesis.

-Stu

robertpnl 25th June 2006 14:47

Quote:

Originally posted by Afrow UK
LicenseLangString $(MUILicense) $(LANG_ENGLISH) "English.rtf"
LicenseLangString $(MUILicense) $(LANG_DUTCH) "Nederlands.rtf"

should be

LicenseLangString MUILicense $(LANG_ENGLISH) "English.rtf"
LicenseLangString MUILicense $(LANG_DUTCH) "Nederlands.rtf"

No parenthesis.

-Stu

Hi Afrow,

Thank you for your reply. But changing the both lines, the problem still repeated. This doesn't work.

I get the next warning again:
- Generating language tables... warning:
- LangString "MUILicense" is not set in language table of
language English
And when I choose for English installation language, no EULA is displayed.

This makes me crazy. Help me..

Robert-Paul

robertpnl 25th June 2006 17:31

Problem solved. Everybody thanks.

onad 27th June 2006 13:52

It would be a nice touch if you could describe what you did to solve it.


All times are GMT. The time now is 05:18.

Copyright © 1999 - 2010 Nullsoft. All Rights Reserved.