Selection Of A Single Character (Stringvar, Stringfeld) - Siemens SINUMERIK 840D sl Programming Manual

Job planning
Hide thumbs Also See for SINUMERIK 840D sl:
Table of Contents

Advertisement

Flexible NC programming
1.9 String operations
1.9.8

Selection of a single character (STRINGVAR, STRINGFELD)

Function
This functionality selects a single character from a string. This applies both to read access
and write access operations.
Syntax
CHAR_ERG = STRINGVAR [IDX] ; Result type: CHAR
CHAR_ERG = STRINGFELD [IDX_FELD, IDX_CHAR] ; Result type: CHAR
Semantics
The character at the specified position is read/written within the string. If the position
parameter is negative or greater than the string, then an alarm is output.
Example messages:
Insertion of an axis identifier into a prepared string.
Program code
DEF STRING [50] MESSAGE = "Axis n has reached position"
MESSAGE [6] = "X"
MSG (MESSAGE)
Parameters
Single character access is possible only to user-defined variables (LUD, GUD, and PUD
data).
This type of access is also possible only for "call-by-value" type parameters in subprogram
calls.
90
Comments
; Returns the message "axis X has
reached position"
Programming Manual, 06/2009, 6FC5398-2BP20-0BA0
Job Planning

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sinumerik 828dSinumerik 840de sl

Table of Contents