Extracts a sub-string of
count characters from the middle of another string (
string), starting at position
firstIndex. If count is -1, the remainder of string is extracted.
|string||yes||String to extract sub-string from.|
|integer||yes||The zero-based index of the first character in string that is to be extracted as a sub-string.|
|integer||yes||The number of characters to extract from string, counting from |
Returns the sub-string from a string.
// Demonstrate usage of strMid
string $str = "This is some text";
// Get 5 characters starting at index 3
$subStr = `strMid $str 3 5`;
// Should be "s is "
// Get rest of string from index 8
$subStr = `strMid $str 8 -1`;
// Should be "some text"