|
|
|
|
UTFConvert (Function) In french: UTFConvertit Converts a string or buffer to the specified format: UTF, ANSI, Unicode. Remark: This function supports UTF-8, UTF-16 Little Endian, UTF-16 Big Endian and UTF-32. // Convert an ANSI string to a UTF-32 Little Endian buffer MyAnsiString is ANSI string = "start" MyBuffer is Buffer = UTFConvert(MyAnsiString, charsetCurrent, charsetUTF32LE)
Syntax
<Result> = UTFConvert(<String or buffer to convert> , <Source charset> , <Destination charset>)
<Result>: Character string or Buffer Conversion result: - UNICODE string if the destination character set corresponds to charsetUnicode.
- ANSI string or buffer otherwise.
- Empty string ("") if there is a conversion error. The ErrorOccurred variable is set to True and the corresponding error message is returned by ErrorInfo.
<String or buffer to convert>: Character string or Buffer String or buffer to convert. <Source charset>: Integer constant Character set of the string or buffer to convert:
| | charsetCurrent | Current character set specified with ChangeCharset (charsetOccidental by default). | charsetUnicode | UNICODE character set. | charsetUTF16BE | UTF-16 Big Endian character set. | charsetUTF16LE | UTF-16 Little Endian character set. | charsetUTF32BE | UTF-32 Big Endian character set. | charsetUTF32LE | UTF-32 Little Endian character set. | charsetUTF8 | UTF-8 character set (used in XML, for example). |
<Destination charset>: Integer Character set that will be used to create the resulting string or buffer:
| | charsetCurrent | Current character set specified with ChangeCharset (charsetOccidental by default). | charsetUnicode | UNICODE character set. | charsetUTF16BE | UTF-16 Big Endian character set. | charsetUTF16LE | UTF-16 Little Endian character set. | charsetUTF32BE | UTF-32 Big Endian character set. | charsetUTF32LE | UTF-32 Little Endian character set. | charsetUTF8 | UTF-8 character set (used in XML, for example). |
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|