Archive: ${LANGUAGE} if-structure


${LANGUAGE} if-structure
Hi guys,

what should I do to get this if-structure working?

!If ${LANGUAGE} == 1031


I want to install a specific file on different languages.

$LANGUAGE is a variable and not a define and it's runtime and not compile time. Use $LANGUAGE instead of ${LANGUAGE} and ${If} or StrCmp instead of !if.

!include LogicLib.nsh
#...
${If} $LANGUAGE == ${LANG_GERMAN}
#...
${EndIf}

Thanks. But now I get these errors:

Error: command StrCmp not valid outside section or function
Error in macro _== on macroline 1
Error in macro _If on macroline 8


As the error says, the code must be located in a section or a function.


Oh, yes. I´m a idiot. Thanks for quickly support!