Concatenation Of Strings (<<) - Siemens SINUMERIK 828D Programming Manual

Hide thumbs Also See for SINUMERIK 828D:
Table of Contents

Advertisement

Example
Program code
DEF BOOL BOOL_ERG
DEF REAL REAL_ERG
DEF AXIS AXIS_ERG
BOOL_ERG=ISNUMBER("1234.9876Ex-7")
BOOL_ERG=ISNUMBER("1234XYZ")
REAL_ERG=NUMBER("1234.9876Ex-7")
AXIS_ERG=AXNAME("X")
1.9.3
Concatenation of strings (<<)
Function
The function "concatenation strings" allows a string to be configured from individual
components.
The concatenation is realized using the operator "<<". This operator has STRING as the
target type for all combinations of basic types CHAR, BOOL, INT, REAL, and STRING.
Any conversion that may be required is carried out according to existing rules.
Syntax
<any_type> << <any_type>
Significance
<any_type>
<<
For example, such a message or a command can be configured from text lists and
parameters can be inserted (for example a block name):
MSG(STRG_TAB[LOAD_IDX]<<BAUSTEIN_NAME)
Job planning
Programming Manual, 07/2010, 6FC5398-2BP40-0BA0
:
Variable, type CHAR, BOOL, INT, REAL or STRING
:
Operator to chain variables (<any_type>) to configure a character string
(type STRING).
This operator is also available alone as a so-called "unary" variant. This
can be used for explicit type converter to STRING (not for FRAME and
AXIS):
<< <any_type>
Flexible NC programming
Comments
; BOOL_ERG == TRUE
; BOOL_ERG == FALSE
; REAL_ERG == 1234.9876Ex-7
; AXIS_ERG == X
1.9 String operations
77

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents