Text

The Text section offers a collection of blocks that enable you to work with text and characters, facilitating communication, data display, and user interaction within your robot programs.

“”

A letter, word, or line of text. It allows you to input an initial text value.

create text with

Returns a new string by combining two texts.

Key points:

  • It takes two strings as input.

  • In the new string, the first (top) string is followed by the second (bottom) string.

to append text “”

Appends text to a variable.

Key points:

  • The to variable must be a string.

  • the text is appended after the original string item.

length of “”

Returns the number of characters in the input text string.

“” is empty

Returns true if a given text input is empty.

In text find first occurrence of text “”

Finds the first occurrence of a specific text within a variable. The index starts from 1. Returns 0 if text is not found. For example, the first occurrence of “abc” in “abc abc” is 1.

From the dropdown list, you can choose to find the last occurrence of a text. If a text can not be found, returns 0. For example, the last occurrence of “abc” in “abc abc” is 4.

In text find get letter

Returns the letter in the specified location. #1 is the first item.

In text find get substring from letter to letter

Returns the substring of the text variable specified between “from” and “to” values.

to Upper Case

Returns uppercase of a string. In the example above, it returns “ABC”.

From the drop down list you can choose the other cases:

  • to lower Case. Returns lowercase of a string. For example, “the lord of the rings”.

  • to Title Case. Returns title case of a string. For example, “The Lord Of The Rings”.

trim spaces from both sides

Trim spaces from both sides of a string.

From the drop down list you can choose the other ways of trimming spaces:

  • trim spaces from left sides. Trim spaces from the left side of a string.

  • trim spaces from right sides. Trim spaces from the right side of a string.