sys.locale read/write property
Get or set the current user locale as a string
, in short format, for example "en-US"
Set this property to nil
to set back the locale to the current Windows user locale.
- This value uses by default the current Windows user locale
- Changing the locale will affect only the current LuaRT program, not the Windows locale setting
- See this link to the Windows supported locale strings
- This setting will affect Datetime formatting and error messages from sys.error and net.error
Example
print("Current language is "..sys.language)
sys.locale = "fr-FR"
print("Current locale language is now "..sys.language)