StrByteLen
f90VB Modules
f90VBDefs, f90VBBStrings
Summary
Function StrByteLen returns the length in bytes of the input string's buffer.
Syntax
| integer(LONG_KIND) function StrByteLen | (Str) |
| { | |
| character(len=*),intent(in):: | Str | |
| integer(OLECHAR_KIND),dimension(:),intent(in):: | Str | |
| type(OLESTRING),intent(in):: | Str | |
| integer(BSTRHNDL_KIND),intent(in):: | Str |
| } | |
Arguments
Str [Input]
String whose length will be determined. It can be any of the f90VB string types (Fortran Strings, Fixed OLE Strings, Fortran OLE Strings or BStrings).
Comments
Function StrByteLen behaves the same as function StrLen, but the result is returned in number of bytes rather than number of characters. ANSI (Fortran) strings generally use one byte per character, while Multibyte strings may use more than one byte for some characters, and only one byte for others. Unicode strings (Fixed OLE Strings, Fortran OLE Strings and BStrings) always use two bytes per character.
Examples
See example for function StrLen.
Related Topics
| For information about | See | |
| Getting the length in characters of a string | StrLen | |
| Getting the trimmed length of a string | StrLenTrim | |
| Getting the trimmed length in bytes of a string | StrByteLenTrim | |