PDL_GetLanguage

Description

Sets the passed buffer variable to the language and country string stored in the Luna (device's GUI) preferences database. Currently, the language string is 5 characters long and has the format <2 letter language code><underscore><2 letter country code>. For example: "EN_UK" — United Kingdom English. The passed buffer is not set to a length longer than bufferLen.

Note:

The 5-character length is not likely to change, though this is not guaranteed. You may want buffer and bufferlen to be larger (i.e., 64 bytes) to encompass future changes.

Syntax

PDL_Err PDL_GetLanguage(char *buffer, int bufferLen);

Argument Description
buffer Pointer to the buffer.
bufferLen Length of the buffer.

Returns

PDL_INVALIDINPUT — buffer is NULL or its length is less than or equal to zero.
PDL_STRINGTOOSMALL — Passed buffer is too small to hold value.
PDL_NOERROR — Success.