Share via


xLanguage Class

The xLanguage class provides access to a list of language IDs and information about existing label files.

Syntax

class xLanguage extends Object

Run On

Called

Methods

  Method Description
Gg949080.pubmethod(en-us,AX.60).gif cancelTimeOut Cancels a previous method call to the setTimeOut method. (Inherited from Object.)
Gg949080.pubmethod(en-us,AX.60).gif equal Determines whether the specified object is equal to the current one. (Inherited from Object.)
Gg949080.pubmethod(en-us,AX.60).gif getTimeOutTimerHandle Returns the timer handle for the object. (Inherited from Object.)
Gg949080.pubmethod(en-us,AX.60).gif handle Retrieves the handle of the class of the object. (Inherited from Object.)
Gg949080.pubmethod(en-us,AX.60).gif new Initializes a new instance of the Object class. (Inherited from Object.)
Gg949080.pubmethod(en-us,AX.60).gif notify Releases the hold on an object that has called the wait method on this object. (Inherited from Object.)
Gg949080.pubmethod(en-us,AX.60).gif notifyAll Releases a lock on the object that was issued by the wait method on this object. (Inherited from Object.)
Gg949080.pubmethod(en-us,AX.60).gif objectOnServer Determines whether the object is on a server. (Inherited from Object.)
Gg949080.pubmethod(en-us,AX.60).gif owner Returns the instance that owns the object. (Inherited from Object.)
Gg949080.pubmethod(en-us,AX.60).gif setTimeOut Sets up the scheduled execution of a specified method. (Inherited from Object.)
Gg949080.pubmethod(en-us,AX.60).gif toString Returns a string that represents the current object. (Inherited from Object.)
Gg949080.pubmethod(en-us,AX.60).gif usageCount Returns the current number of references, that is, the value of the reference counter, that the object has. (Inherited from Object.)
Gg949080.pubmethod(en-us,AX.60).gif wait Pauses a process. (Inherited from Object.)
Gg949080.pubmethod(en-us,AX.60).gif xml Returns an XML string that represents the current object. (Inherited from Object.)
Gg949080.pubmethod(en-us,AX.60).gif Gg949080.static(en-us,AX.60).gif ::index2languageID Retrieves the language ID (for example, "en-us") of the specified language.
Gg949080.pubmethod(en-us,AX.60).gif Gg949080.static(en-us,AX.60).gif ::labelFileCount Returns the number of label files.
Gg949080.pubmethod(en-us,AX.60).gif Gg949080.static(en-us,AX.60).gif ::labelFileNumber2LanguageID
Gg949080.pubmethod(en-us,AX.60).gif Gg949080.static(en-us,AX.60).gif ::languageCount
Gg949080.pubmethod(en-us,AX.60).gif Gg949080.static(en-us,AX.60).gif ::languageID2Description Returns the name of the specified language (for example, "English (United States)"), given the language ID.
Gg949080.pubmethod(en-us,AX.60).gif Gg949080.static(en-us,AX.60).gif ::languageID2LCID
Gg949080.pubmethod(en-us,AX.60).gif Gg949080.static(en-us,AX.60).gif ::lcid2languageID

Top

Remarks

ISO 639 defines the names of languages, such as "en" for English.

Microsoft has listed a set of language codes, such "en-us" for English (United States). These language codes are referred to in Microsoft Dynamics AX as Language IDs.

Microsoft Dynamics AX uses "ko-jo" for Korean (Johab). In the Microsoft list, "ko" is both Korean and Korean (Johab).

Microsoft Dynamics AX uses "no-ny" for Norwegian (Nynorsk). In the Microsoft list, "no" is both Norwegian (Bokmal) and Norwegian (Nynorsk).

Microsoft Dynamics AX uses "es-tr" to represent Spanish (Spain - Traditional Sort). In the Microsoft list, "es" is both Spanish (Spain - Modern Sort) and Spanish (Spain - Traditional Sort).

A language name in the following format, such as "English (United States)", is referred to as the description in Microsoft Dynamics AX.

Examples

The following example prints all the language IDs from the Microsoft list and a list of existing label files.

static void aaaTestLanguage(args a) 
{ 
    int i; 
    int cnt; 
    str languageID; 
    str description; 
    str shortName; 
 
    cnt = xlanguage::languageCount(); 
    for (i = 0; i<=cnt; i++) 
    { 
        languageID =xLanguage::index2languageID(i); 
        print "Language ", i, ":", languageID, ":"; 
    } 
    cnt = xLanguage::labelFileCount(); 
    for (i = 0; i<=cnt; i++) 
    { 
        shortName =xLanguage::labelFileNumber2LanguageID(i); 
        languageID =xLanguage::index2languageID(i); 
        description = xLanguage::languageID2Description(languageID); 
        print i, ":", shortName, ":", description; 
    } 
    pause; 
}

Inheritance Hierarchy

Object Class
  xLanguage Class