Left - Crestron SIMPL+ Reference Manual

Language reference guide
Hide thumbs Also See for SIMPL+:
Table of Contents

Advertisement

Software
®
224
SIMPL+

Left

Name:
Left
Syntax:
STRING Left(STRING SOURCE, INTEGER NUM);
Description:
Takes the leftmost NUM characters of SOURCE and returns them in an output string.
Parameters:
SOURCE is a STRING containing the source string.
NUM is an INTEGER that tells LEFT how many characters to use in the
computation.
Return Value:
A string representing the leftmost NUM characters of SOURCE. If NUM is greater
than the number of characters in SOURCE, then the return is identical to SOURCE.
Example:
STRING_INPUT Var$[100];
STRING Temp$[100];
CHANGE Var$
{
Temp$ = LEFT(Var$, 5);
PRINT("Left most 5 characters of %s are %s\n", Var$, Temp$);
}
In this example, if Var$ is "abcdefghijk", Temp$ will contain "abcde".
Version:
SIMPL+ Version 1.00
Crestron SIMPL+
Language Reference Guide - DOC. 5797G
®

Advertisement

Table of Contents
loading

Table of Contents