Siemens SINUMERIK 840D sl Commissioning Manual page 685

Basesoftware and operating software
Hide thumbs Also See for SINUMERIK 840D sl:
Table of Contents

Advertisement

Example
Default settings for the following examples:
VAR1.VAL = "This is an"
VAR8.VAL = 4
VAR14.VAL = 15
VAR2.VAL = "Error"
$85001 = "This is an"
$85002 = "Alarm text"
Editing strings:
● Chaining of strings:
● Deleting a variable:
● Setting a variable with a text variable:
● Data type matching:
● Treatment of numerical values:
● Quotation marks within a string:
● System or user-variable strings dependent on variable content:
See also
STRING functions (Page 124)
SINUMERIK Integrate Run MyScreens (BE2)
Programming Manual, 03/2013, 6FC5397-1DP40-3BA1
VAR12.VAL = VAR1 << " Error."
VAR10.VAL = ""
;Result: Blank string
VAR11.VAL = VAR1.VAL
VAR13.VAL ="This is the " << (VAR14 - VAR8) << ". error"
;Result: "This is the 11th error"
VAR13.VAL = "Error" << VAR14.VAL << ": " << $85001 << $85002
;Result: "Error 15: "This is an alarm text"
IF VAR15 == "Error"
VAR16 = 18.1234
;Result: VAR16 equals 18.1234,
;if VAR15 equals "Error".
ENDIF
VAR2="Hello, this is a " Test""
;Result: Hello, this is a " Test"
VAR2.Var = "$R[" << VAR8 << "]"
;Result: "This is an error"
;Result: "This is an"
;Strings in IF statement
;Result: $R[4]
Variables
5.12 Use of strings
67

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sinumerik 840de sl

Table of Contents