StringByteLength()

Found an issue in the documentation ? Please report it here !

Moderator: Documentation Editors

Little John
Addict
Addict
Posts: 4846
Joined: Thu Jun 07, 2007 3:25 pm
Location: Berlin, Germany

StringByteLength()

Post by Little John »

see https://www.purebasic.com/documentation ... ength.html
Syntax

Result = StringByteLength(String$ [, Format])
For the optional 'Format' parameter, three possible values are mentioned.
But it is not explained which of them the default value is, if this parameter is omitted when calling StringByteLength().

According to the following code

Code: Select all

; PB 6.30

Debug StringByteLength("abc")               ; -> 6
Debug StringByteLength("abc", #PB_Unicode)  ; -> 6
Debug StringByteLength("abc", #PB_Ascii)    ; -> 3
Debug StringByteLength("abc", #PB_UTF8)     ; -> 3
the default value is #PB_Unicode.
However, this should be documented in the help.