String Library
String Library provides a group of useful functions intended for working with strings. The library perfectly complement build-in functions of MetaTrader. After copying the files into corresponding directories you can include the library by adding following line to your files: #include <StringLib.mqh>.
Functions:
string stringReplaceAll(string str, string toFind, string toReplace)— Returns a new string resulting from replacing all occurrences oftoFindin this string withtoReplace.string stringReplaceFirst(string str, string toFind, string toReplace)— Replaces the first substring of this string that matchestoFindwithtoReplace.void stringSplit(string& output[], string input, string token)— Splits inputstringintooutputarray around giventoken.string stringTrim(string str)— Returns a copy of the string, with leading and trailing whitespace omitted.bool stringStartsWith(string str, string prefix)— Tests if given string starts with the specifiedprefix.bool stringEndsWith(string str, string suffix)— Tests if given string ends with the specifiedsuffix.string stringToLowerCase(string str)— Converts all of the characters in the given string to lower case (works only with English alphabet).string stringToUpperCase(string str)— Converts all of the characters in the given string to upper case (works only with English alphabet).bool stringEqualsIgnoreCase(string str1, string str2)— Compares one string to another string, ignoring case considerations (works only with English alphabet).
Download
and unpack it in experts subdirectory.
