Difference between revisions of "LeftTrim"
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
− | + | {{HelpFiles}} | |
− | {{HelpFiles}} | + | |
+ | ==== leftTrim ==== | ||
− | + | Removes all occurrences of a set of characters specified in an array from the beginning of the input string. | |
− | + | '''Syntax''' | |
− | ''' | + | leftTrim(''inputString'', ''charArray'') |
− | leftTrim(''inputString | + | leftTrim(''inputString'') |
− | + | '''Arguments''' | |
− | '' | + | ''inputString'': is a string expression. |
− | '' | + | ''charArray'': is an array of string whose items are only characters to be trimmed from the beginning of the input. If this one is not specified, the function will remove all occurrences of empty spaces from the beginning of the input string. |
− | '' | + | '''Return type''' |
− | + | string | |
− | + | '''Example''' | |
− | '' | + | ''array charArray = {"a", "b", "c"};'' |
− | + | ''string input = "catglob";'' | |
− | string input | + | ''string result = leftTrim(input, charArray);'' |
− | + | ''print(result);'' | |
− | + | ''//tglob'' | |
− | + | ''input = " catglobe ";'' | |
− | + | ''result = leftTrim(input);'' | |
− | result | + | ''print(result);'' |
− | + | ''//"catglob " '' | |
− | + | '''Availability''' | |
− | + | Version 5.2 __NOTOC__ <!-- imported from file: 683.htm--> | |
− | + | [[Category:String_Functions]] | |
− | |||
− |
Latest revision as of 11:52, 22 December 2011
leftTrim
Removes all occurrences of a set of characters specified in an array from the beginning of the input string.
Syntax
leftTrim(inputString, charArray)
leftTrim(inputString)
Arguments
inputString: is a string expression.
charArray: is an array of string whose items are only characters to be trimmed from the beginning of the input. If this one is not specified, the function will remove all occurrences of empty spaces from the beginning of the input string.
Return type
string
Example
array charArray = {"a", "b", "c"};
string input = "catglob";
string result = leftTrim(input, charArray);
print(result);
//tglob
input = " catglobe ";
result = leftTrim(input);
print(result);
//"catglob "
Availability
Version 5.2