EasyManua.ls Logo

Siemens SIMATIC S7-1200 - Page 382

Siemens SIMATIC S7-1200
1614 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Extended instructions
9.2 String and character
S7-1200 Programmable controller
382 System Manual, V4.2, 09/2016, A5E02486680-AK
Example: Meaning of the SIZE parameter
To limit the length of the block name to a certain number of characters, specify the maximum
length at the SIZE parameter. If GetBlockName truncates the name, it indicates the
truncation by the character "..." (Unicode character 16#2026) at the end of the name. Note
that this character has the length 1.
The following example illustrates the meaning of the SIZE parameter. GetBlockName has
read out the following block name: Level1_gbn (The double quotes at the start and end
belong to the name.)
SIZE
GetBlockName returns
Explanation
1 '...'
First character of WSTRING:'
Identifier that the name was truncated: ...
Last character of WSTRING:'
2 '"...'
First character of WSTRING:'
The first character of the name and identifier that the
name was truncated:"...
Last character of WSTRING:'
3 '"L...'
First character of WSTRING:'
The first two characters of the name and identifier that
the name was truncated:"... "L...
Last character of WSTRING:'
6 '"Leve...'
First character of WSTRING:'
The first five characters of the name and identifier that
the name was truncated: "Leve...
Last character of WSTRING:'
0 '"Level1_gbn"'
First character of WSTRING:'
All characters of the name: "Level1_gbn"
Last character of WSTRING:'
GetBlockName writes the name of the block at the RET_VAL parameter. If the name of the
block is longer than the maximum length of WSTRING, it truncates the name.

Table of Contents

Other manuals for Siemens SIMATIC S7-1200

Related product manuals