subString()
Returns the substring starting at byte position startindex and ending at endindex-1 or the end of the string.
Syntax
String subString(Numeric startindex [, Numeric endindex ])
- startindex is the index in the current String where the substring starts. The first byte of a string is at position 0.
- endindex (optional) is the end index. If endindex is specified, the substring ends at endindex-1. If endindex is not specified, the substring extends to the end of the current String.
Example
The value of the String order_line.billState
is "smiles" (indexes
012345).
The following code returns the substring "mile":
order_line.billState.subString(1,5)