Reference

Class

RiString

Name

substr

Description Extracts the characters from this objects contained string, beginning at 'start' and continuing through the specified number of characters, and sets the current text to be that string. (from Javascript String)
Syntax
substr(start);
substr(start, length);
Parameters
intThe index where to start the extraction. First character is at index 0
int(optional) The index where to stop the extraction. If omitted, it extracts the rest of the string
Returns
String
Example
myRiString = new RiString("He ate the apple."); 
myRiString.substr(3,3); // ate
Platform Java / Javascript