Current user's language

EvREvR Member Posts: 178
Hi all,

A pretty basic question, but is it possible to get the client language of the current user in C/AL?

Gr, Erik

Best Answer

Answers

  • RockWithNAVRockWithNAV Member Posts: 1,139
    Yep as Jan Suggested GLOBALLANGUAGE function is the only keyword in NAV which you can use AFAIK.
  • EvREvR Member Posts: 178
    And what exactly is the GLOBALLANGUAGE?
    MSDN doesn't really explain anything, as is often the case.

    Is it the service language, or the actual language in which the user's client is running?
  • Jan_VeenendaalJan_Veenendaal Member Posts: 206
    :smiley: you asked for the client's language, so that's what you get. This is for all client types.

    The function WINDOWSLANGUAGE returns the OS language setting (which might of course be different)

    I think there is no function available to get the service's language - the service has to serve any (available) language so it its language should not be of any importance.


    In the Classic Client ( NAV 2009R2 and earlier ) there also was a LANGUAGE function, that could be set for each form, report or dataport. This function is not available in 3-tier deployments.
    Jan Veenendaal
  • EvREvR Member Posts: 178
    edited 2016-05-25
    Yep that's what I asked for, but that's not what 'GLOBALLANGUAGE' suggests to me and MSDN wasn't clear. Global, to me, suggest some kind of common language (service). I would have called it 'CLIENTLANGUAGE' myself :smile:
    Thanks.
  • Jan_VeenendaalJan_Veenendaal Member Posts: 206
    I agree. Naming is unclear in this case.
    Jan Veenendaal
Sign In or Register to comment.