Returns the i-th substring of a delimited string text.

Syntax

XIH.GetPart(text, delimiter, i)

Parameters

Parameter

Data type

Description

Sample

text

string

Text to be cut apart

"cut me, apart"

delimiter

string

A string that defines the boundaries between text parts

","

i

int

Specifies which text part should be cut out starting with zero

0

Remarks

i=0 returns the substring up to the first delimiter.

Available starting from version 5.5.

Returns a string.

Examples

XIH.GetPart("First part delimiter second part delimiter third part", "delimiter", 0)
XIH.GetPart("First part delimiter second part delimiter third part", "delimiter", 1)
XIH.GetPart("First part delimiter second part delimiter third part", "delimiter", 2)

Related