Scense

Full Version: Howto create a Language (enviroment) variable
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Good afternoon,

I would like to know howto create a Language environmentment variable? We are using XA_Duits, XA_Engeles, XA_Nederlands (in active directory)and i would like to store these groups for the user that logs in as a variable. And i would like to store it as IETF (nl-NL, en-US) and as a simple variable: nl, en.

So how do i convert these Active directory groups to variable i can use in: http://www.scense.com/forum/showthread.php?tid=14 to create my own custom ini file with %variable% in the ini file.

I have attached an *.ini file that is used by an application.
The simplest way to tackle this:
  • Create an Environment action in the logon sequence for each language(group), create a variable (e.g. LANGUAGE) and set it to 'nl-NL' or one of the others.
  • Make sure the environment variable is propagated
  • Make sure this action only executes if the user is a member of the corresponding XA_ group, so set a condition on this action that tests for the correct groupmembership
So, in your example you could add 3 Environment actions (one for each language group) and set the LANGUAGE environment variable accordingly.
At next logon %LANGUAGE% will resolve to one of the IETF strings.

Cheers,
Richard