UDFB Parameters window

Use the
Parameters
window to:
  • Create or delete input or output parameters for user-defined function blocks (UDFB) or user-defined functions (UDF).
  • Edit the parameters of local variables for UDFBs and UDFs.
  • Move a variable up or down in the UDFB or UDF.
UDFs are limited to one output parameter with a modifiable data type. The properties vary with the instruction block type.
Items in the UDFB Parameter window
Item
Description
Possible Values
Name
Specifies the parameter name.
The naming conventions are as follows:
  • The name is limited to 40 characters, and can contain underscores, numbers, or letters.
  • The name starts with a letter or an underscore.
  • The name cannot end with an underscore.
  • The name cannot contain consecutive underscores.
The naming conventions are based on the IEC-1131 rules for identifiers.
Data type
Selects the parameter data type.
BOOL, BYTE, DATE, DINT, DWORD, INT, LINT, LREAL, LWORD, REAL, SINT, STRING, TIME, UDINT, UINT, ULINT, USINT, WORD, USER ARRAYS, Defined words, Function blocks.
For information about data types, see Data types overview.
Dimension
Specifies the dimension of the instruction.
Dimension is defined as a positive double integer (DINT) value.
For example,
  • [1..10] for a one-dimensional value
  • [1..4,1..7] for a two-dimensional value
The recommended maximum size limit for a multi-dimensional array is [1..400,1..40].
Comment
Contains comments for the parameter.
Free-format text.
Move up
Moves up the selected parameter.
N/A
Move down
Moves down the selected parameter.
N/A
New input
Creates an input parameter.
N/A
New output
Creates an output parameter. UDFs are limited to one output parameter with a modifiable data type.
N/A
Delete parameter
Deletes the selected parameter.
N/A
Provide Feedback
Have questions or feedback about this documentation? Please submit your feedback here.
Normal