Skip to main content

Transfer Object Scripts

When you create a new script of the type “Transfer object”," three predefined methods are available:

Methods in the Transfer Object

MethodDescription
InitializeThe method is called once when the OPC router is started.
WriteThe method is called after another transfer object has written data to this transfer object. This is the code that is executed when this object serves as the destination of a data transfer.
ReadThe method is called before another transfer object reads data from this transfer object. This is the code that is executed when this object serves as the source of a data transfer.

You can create parameters and variables via the “Settings – Manage Parameters” menu. You can define the following properties for the parameters:

Properties of Parameters

PropertyDescription
NameName of the parameter
Array

Yes | No

Specifies whether the parameter is an array. You can use an array as an output parameter, for example, as a source for an SQL INSERT statement.

PropertyDescription
Parameter TypeData Type
Parameter Direction
  • Input: Input parameter. In flow configuration, this parameter can serve as the destination of a data transfer.
  • Output: Output parameter. In Flow configuration, this parameter can serve as the source of a data transfer.
  • Both: The parameter is both an input and an output parameter.
  • None: A variable that is not visible to the Flow Designer and is used only within the script.

When you create a new script, the script editor opens automatically.