String Manipulation Instructions

Instruction

Action

ADDSTRING

Concatenation of two character strings.

ASC

Return the ASCII code of the first character of a string.

ASCIIFIELD

Retrieve, from an ASCII buffer, ASCII fields separated by a given character.

CHR

Return the ASCII character of the code passed as an argument.

CMPSTRING

Compare two character strings.

FORMAT

Returns a string including an inserted formatted value.

LCASE

Convert all the characters of a string to lower case.

LEFT

Return the first N characters of a string.

LEN

Return the length of a string.

LTRIM

Return a copy of a string without any leading spaces.

MID

Return a sub-string of a character string.

REPLACE

Search for, and replace, a sub-string.

RIGHT

Return the last N characters of the string.

RTRIM

Return a copy of a string without any trailing spaces.

SPACE

Return a string composed of N spaces.

STRING

Return a string composed of N instances of a character.

TEXTVAR

Manipulate character strings.

UCASE

Convert all the characters of a string to upper case.

String separator characters must be prefixed with a the backslash ("\") escape character so that they are interpreted correctly:

\\ for the backslash

\' for the simple quote

\" for the double quote

\t for the tab

\r for the carriage return

\n for the new line

For example to include a simple quote in a string:

"a quote needs to be escaped, if not, it doesn\'t work"