String Handling Routines

From RAD Studio
Jump to: navigation, search

Go Up to API Categories Index

This topic lists the string types and links to the pages that list and describe the various string handling routines.

Important: Some string types are not supported on all platforms.
For string handling, we recommend that you use System.SysUtils.TStringHelper, which is supported on all platforms.
String Type Routines

System.SysUtils.TStringHelper supports the default string type (UnicodeString or String) and works with either 0-based or 1-based strings. For more information, see Migrating Delphi Code to Mobile from Desktop.

TStringHelper Methods

Default string type:

UnicodeString Methods

AnsiString type:

  • System.AnsiStrings defines routines for handling the AnsiString type.
  • System.SysUtils defines routines with the same names (such as AnsiIndexStr) as those defined in System.AnsiStrings).
    The SysUtils versions are useful for supporting older code that still uses the Ansixxxx routines.
  • System.AnsiStringBase is the base class for the C++ analog of the Delphi long string type.
  • System.AnsiStringT is a template class used when handling a Delphi AnsiString that has a code page specified with it.

System.WideStrings.TWideStrings is the base class for objects that represent a list of Unicode strings.

TWideStrings Methods

System.Classes.TStrings is the base class for objects that represent a list of strings.

TStrings Methods

System.ShortString is maintained for backward compatibility.

System.RawByteString (not recommended)

See AnsiString type.


String pointers


See Also