This action sends data to any external device which accepts TCP/IP connection on a predefined port number.
Send Data to TCP/IP Port establishes connection with a device, sends the data and terminates the connection. The connection and communication is governed by the client – server handshake that occurs when initiating or terminating the TCP connection.
Connection Settings group sets connection details.
-
Reply to sender: Enables direct reply to the socket from which the trigger data originates. Use this option to provide feedback about the printing process.
Note This option is available in Loftware Automation.
Prerequisites for Reply to sender setting are:
-
Remote party does not close the communication channel, once the message gets delivered.
-
Send Data to TCP/IP Port action is used within the TCP/IP Server trigger.
-
Do not configure the Execution Event in the TCP/IP Server trigger as On client disconnect.
-
-
Destination (IP address:port): destination address and port of the TCP/IP server. Hard-code the connection parameters and use fixed host name or IP address or use variable connection parameters by clicking the right arrow and selecting a predefined variable. For more information, see section Combining Values in an Object in Loftware Automation user guide.
Example 69. Example
If the variable
hostname
provides the TCP/IP server name and the variableport
provides the port number, enter the following parameter for the destination:[hostname]:[port]
-
Disconnect delay: prolongs the connection with the target socket for the defined time intervals after the data has been delivered. Certain devices require more time to process the data. Insert the delay value manually or click the arrows to increase or decrease it.
-
Save data reply in a variable: selects or creates a variable that stores the server reply. Any data received from the TCP/IP server after passing the "disconnect delay" is stored in this variable.
Note | |
---|---|
Send Data to TCP/IP Port action is executed on Web Printing Server and not on the Web Printing Client. If you use Send Data to TCP/IP Port action in LoftwareWeb Client and you want to execute locally (bypassing the Web Printing Server), add the prefix "LOCAL_" to your action name. |
Content group defines the content to be sent to a TCP/IP server.
Tip | |
---|---|
Use fixed content, mix of fixed and variable content, or variable content alone. To enter variable content, click the button with arrow to the right of data area and insert a variable from the list. For more information, see section Combining Values in an Object in Loftware Automation user guide. |
-
Data: content to be sent outbound.
-
Encoding: encoding type for the sent data. Auto defines the encoding automatically. If needed, select the preferred encoding type from the drop-down list.