Technical data
Creating Data Blocks
11.4 Editing and Saving Data Blocks
Programming with STEP 7
274 Manual, 05/2010, A5E02789666-01
11.4.4 Entering and Displaying the Structure of Data Blocks Referencing a UDT
Input
When you assign a data block to a user-defined data type, the data structure of the user-defined
data type defines the structure of the data block. Any changes can only be made in the associated
user-defined data type.
1. Open the user-defined data type (UDT).
2. Edit the structure of the user-defined data type.
3. Create the data block again.
Display
You can only display how the variables were declared in the user-defined data type in the
declaration view of the data block.
1. Open the data block.
2. Display the declaration view of the data block if this view is not set already.
3. See below for more information on the table displayed.
The declaration view cannot be modified. Any changes can only be made in the associated
user-defined data type.
Column Explanation
Address Displays the address which STEP 7 automatically assigns for the variable.
Name The symbolic name assigned in the variable declaration of the user data type.
Type Displays the data types assigned in the variable declaration of the user-defined data type.
The variables can have elementary data types, complex data types, or user-defined data
types.
Initial Value The initial value that you entered for the variable in the user-defined data type if you do not
want the software to use the default value.
When you save a data block for the first time, the initial value is used as the actual value if
you have not explicitly defined actual values for the variables.
Comment The comment entered in the variable declaration for the user-defined data type to document
the data element.
Note
For data blocks that are assigned to a user-defined data type, you can only edit the actual values
for the variables. To enter actual values for the variables, you must be in the data view of data
blocks.