sysLib.setLocale

The system function sysLib.setLocale is used in page handlers. The function sets the Java locale, which determines these aspects of run-time behavior:

You might present a list of languages on a Web page, for example, and set the Java locale based on the user's selection. The new Java locale is in use until one of the following occurs:

In the cases mentioned, the next Web page reverts (by default) to the Java locale specified in the browser.

If the user submits a form or clicks a link that opens a new window, the Java locale in the original window is unaffected by the locale in the new window.

sysLib.setLocale conforms to the JDK 1.1 and 1.2 API documentation for class java.util.Locale. See ISO 639 for language codes and ISO 3166 for country codes.


sysLib.setLocale syntax diagram

languageCode

A two-character language code specified as a literal or contained in an item of type CHAR. Only language codes that are defined by ISO 639 are valid.

countryCode

A two-character country code specified as a literal or contained in an item of type CHAR. Only country codes that are defined by ISO 3166 are valid.

variant

A variant, which is a code specified as a literal or contained in an item of type CHAR. This code is not part of a Java specification but depends on the browser and other aspects of the user environment.

Related concepts
PageHandler part