Skip to content
Reference > Methods

strSplit(text,delim)

Definition

List strSplit(String text, String delim)

Description

Splits line into a list using the supplied delimiter, returns that list.

Parameter Definition

Name Type Description
text String The string to split
delim String delimiter, literal not a pattern

Examples

1
2
3
4
List r1 = strSplit("these are some words"," "); // r1 == [these, are, some, words]
List r2 = strSplit("these are words that are split by a word"," are "); // r2 == [these, words that, split by a word]
List r3 = strSplit("Simple|case|right|here","|"); // r3 == [Simple, case, right, here]
List r4 = strSplit("abcd",""); // r4 == [a, b, c, d]