Technical data
Basics of Creating Logic Blocks
10.4 General Notes on Entering Statements and Comments
Programming with STEP 7
Manual, 05/2010, A5E02789666-01 251
10.4.3 Entering Shared Symbols in a Program
Using the menu command Insert > Symbol you can insert symbols in the code section of your
program. If the cursor is positioned at the beginning, the end, or within a string, the symbol is
already selected that starts with this string - if such a symbol exists. If you change the string, the
selection is updated in the list.
Separators for the beginning and end of a string are, for example, blank, period, colon. No
separators are interpreted within shared symbols.
To enter symbols, proceed as follows:
1. Enter the first letter of the required symbol in the program.
2. Press CTRL and J simultaneously to display a list of symbols. The first symbol starting with the
letter you entered is already selected.
3. Enter the symbol by pressing RETURN or select another symbol.
The symbol enclosed in quotation marks is then entered instead of the first letter.
In general the following applies: if the cursor is located at the beginning, the end, or within a string,
this string is replaced by the symbol enclosed in quotation marks when inserting a symbol.
10.4.4 Title and Comments for Blocks and Networks
Comments make your user program easier to read and therefore make commissioning and
troubleshooting easier and more effective. They are an important part of the program
documentation and should certainly be made use of.
Comments in LAD, FBD and STL Programs
The following comments are available:
• Block title: title for a block (max. 64 characters)
• Block comment: documents the whole logic block, for example, the purpose of the block
• Network title: title for a network (max. 64 characters)
• Network comment: documents the functions of a single network
• Comment column in the variable detail view: comments the declared local data
• Symbol comment: comments that were entered for an address when its symbolic name was
defined in the symbol table.
You can display these comments using the menu command View > Display with > Symbol
Information.
In the code section of a logic block you can enter the block title and network title, and block
comments or network comments.