Omron SYSMAC C200H-ASC02 Operation Manual page 69

Ascii unit
Hide thumbs Also See for SYSMAC C200H-ASC02:
Table of Contents

Advertisement

BASIC Language
SPACE$ Function
STR$ Function
STRING$ Function
TAB Function
Format:
RIGHT$(<x$>,<i>)
<x$> is the string to be searched.
<i> is the number of characters to be returned.
Example:
A$ = RIGHT$(B$,5)
Remarks:
<i> must be an integer from 0 to 255. If <i> is 0, an empty string is returned
as the function value. If <i> is greater than the number of characters in <x$>,
the entire character string is returned.
Purpose:
To return a string of spaces of the specified length
Format:
SPACE$(<x>)
<x> is the number of spaces.
Example:
A$ = "CF"+SPACE$(5)+"BASIC"
Remarks:
<x> must be from 0 to 255. If <x> is not an integer, it will be rounded off. If 0
is specified, an empty character string is returned.
Purpose:
Converts the specified numeric value into a character string
Format:
STR$(<x>)
Example:
B$ = "A"+STR$(123)
Remarks:
The VAL function performs the inverse operation.
Purpose:
To return a character string of the specified character and length
Formats:
STRING$(<i>,<j>)
STRING$(<i>,<x$>)
<i> is the number of characters to be returned.
<j> is the ASCII code of some character.
<x$> is a given string.
Example:
A$ = STRING$(10,"A")
Remarks:
<i> and <j> must be from 0 to 255.
An empty string is returned if the <i> is 0.
If the <x$> is made up of two or more characters, only the first character is
used.
Purpose:
To move the cursor to a specific position on the terminal display
Format:
TAB(<i>)
<i> is the cursor position counting from the leftmost side of the
display.
Example:
PRINT "CF" TAB (10) "BASIC"
Section 4-2
59

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents