StringByteLength()
语法
Result = StringByteLength(String$ [, Format])概要
Returns the number of bytes required to store the string in memory in a given format.
参数
String$ The string to use. Format (optional) The destination format to use. It can be one of the following value: #PB_Ascii : Ascii format #PB_UTF8 : UTF8 format #PB_Unicode: UTF16 formatIf omitted, the mode of the executable (unicode or ascii) is used.
返回值
The number of bytes required to store the string in memory in a given format.
Remarks
The number of bytes returned does not include the terminating Null-Character of the string. The size of the Null-Character is 1 byte for Ascii and UTF8 mode and 2 bytes for Unicode mode.
示例
Debug StringByteLength("�, #PB_UTF8) ; will display 2
已支持操作系统
所有