Text.Join

From Xojo Documentation

Method

Text.Join(items() As Text, separator As Text) As Text

Supported for all project types and targets.

Creates a new Text object by concatenating each item in the items array together. If separator is not empty, it will be inserted between each item when performing the concatenation. If the items array is empty, an empty Text value is returned.

Parameters

Value Description
items The array to join into a single text.
separator The separator used to separate each element in the array when joined into the text.

Exceptions

Sample Code

Create a text from the array containing "Hello" and "World":

Dim words() As Text = Array("Hello", "World")

Dim newText As Text
newText = Text.Join(words, ",") // newText = "Hello,World"