Skip to content

StringToUnicodeChar

Convert an ansistring to a null-terminated array of Unicode characters.

Declaration

Source position: ustringh.inc line 47

  function StringToUnicodeChar(const Src: RawByteString; 
                              Dest: PUnicodeChar; DestSize: SizeInt)
                               : PUnicodeChar;

Description

StringToUnicodeChar converts the ansistring S to a unicodestring and places the result in Dest. The size of the memory location pointed to by Dest must be given in DestSize. If the result string is longer than the available size, the result string will be truncated.

The function always returns Dest.

Errors

No check is performed to see whether Dest points to a valid memory location.

See also

Name Description
UnicodeCharLenToString Convert a memory buffer with Unicode characters to a unicodestring
UnicodeCharToString Convert Unicode character to string