System.SysUtils.StrCharLength

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

function StrCharLength(const Str: MarshaledAString): Integer;
function StrCharLength(const Str: PWideChar): Integer;

C++

extern DELPHI_PACKAGE int __fastcall StrCharLength _DEPRECATED_ATTRIBUTE1("Moved to the AnsiStrings unit") (const char * Str)/* overload */;

Properties

Type Visibility Source Unit Parent
function public
System.SysUtils.pas
System.SysUtils.hpp
System.SysUtils System.SysUtils

Description

Warning: The ANSI version of StrCharLength is deprecated. Please use the AnsiStrings unit.

Returns the length, in bytes, of a character.

StrCharLength returns the size, in bytes, of the first character in Str. This value can be 1 or 2 on Windows, and 1 to 6 on MacOS.

See Also