string_length (text: STRING): INTEGER
Returns the number of characters in text. Use this with substring and string_pos to make sure the string is long enough.
substring
string_pos
string functions
script cut_strings is str := 'test' pos := string_pos (str, 't', 1) -- pos = 1 if (pos > 0) then s := substring (str, pos, string_length (str) - pos) -- s == 'est' pos := string_pos (s, 't') -- pos = 3 end end