Converts a string from UTF-8 to the local code page.
#include <unilib.h> int utf8n2loc ( UniRuleTable_t table, char *dest, size_t *destLen, const char *src, size_t srcLen, char noMapCh, int noMapFlag);
(IN) Specifies the table to use for the conversion. To use the host's default code page, specify UNI_LOCAL_DEFAULT. Otherwise, specify the value returned from the UniGetTable function.
(OUT) Points to the converted string.
(IN/OUT) Points to the maximum number of bytes that the destination string can hold when the function is called. When the function returns, it contains the number of bytes in the converted string.
(IN) Points to the source string in UTF-8 format.
(IN) Specifies the number of UTF-8 characters in the source string.
(IN) Specifies an arbitrary character to be used in place of a source character for which no mapping can be found in the table. The noMapFlag parameter determines whether this character is used.
(IN) Specifies whether to replace an unmappable character or simply return an error. It uses one of the following flags:
If successful, returns 0. Otherwise, returns a negative error code: