● Remove spaces (from left or from the right)
●
Insert values or strings with formatting identifiers
LEN function: Length of a string
Syntax: LEN
(string | varname)
Description: Determines the number of characters in a string
Parameters: string Every valid string expression. NULL is output if string is
empty.
varname Any valid declared variable name
Only one of the two parameters is allowed.
Example
DEF VAR01
DEF VAR02
LOAD
VAR01="HALLO"
VAR02=LEN(VAR01) ; Result = 5
END_LOAD
INSTR function: Search for character in string
Syntax: INSTR
(Start, String1, String2 [,Direction])
Description: Searches for characters
Parameters: Start Starting position for searching for string1 in string2. En‐
ter 0 to start searching at the beginning of string2.
String1 Character that is being searched for.
String2 Character string in which the search is being made.
Direction (optional) Direction in which the search is being made.
0: From left to right (default setting)
1: From right to left
0 is returned if string1 does not occur in string2.
Example
DEF VAR01
DEF VAR02
LOAD
Programming commands
6.3 Functions
SINUMERIK Integrate Run MyScreens
152 Programming Manual, 10/2015, 6FC5397-3DP40-5BA3