Files
mql5-skills/skills/mql5/references/docs/34-standardlibrary/2108-standardlibrary-stringoperations-cstring.md
T
2026-06-23 21:47:51 +08:00

1.5 KiB

CString

CString is a class for simplified access to the variables of string type.

Description

CString class provides simplified access to MQL5 API functions working with string variables.

Declaration

   class CString: public CObject

Title

   #include <Strings\String.mqh>

Inheritance hierarchy
   CObject
       CString

Class Methods by Groups

Data access methods
Str Gets a string
Len Gets length of a string
Copy Copies a string copy
Fill methods
Fill Fills a string
Assign Assigns a string
Append Appends a string
Insert Inserts a string
Compare methods
Compare Compares strings
CompareNoCase Performs a case insensitive string comparison
Substring methods
Left Gets a substring from the left
Right Gets a substring from the right
Mid Gets a substring from the middle
Trim/delete methods
Trim Trims a string from the left and from the right
TrimLeft Trims a string from the left
TrimRight Trims a string from the right
Clear Clears a string
Convert methods
ToUpper Converts a string to uppercase.
ToLower Converts a string to lowercase.
Reverse Reverses a string
Search methods
Find Searches a substring left to right
FindRev Searches a substring right to left
Remove Deletes a substring
Replace Replaces a substring
Methods inherited from class CObject
Prev, Prev, Next, Next, Save, Load, Type