Reference

Class

RiString

Name

substring

Description Extracts the characters from a string, between two specified indices, and sets the current text to be that string.
Syntax
substring(from);
substring(from, to);
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.substring(0,6); // He ate
Platform Java / Javascript