Opens a communication session to the T-Server specified by the parameters server_host_name and server_port, which are taken from Configuration Server. It designates the event-processing function that will be invoked each time an event from T-Server is detected.
Use the TOpenServerEx() function (rather than TOpenServer()) to reconnect after a T-Server session has been unexpectedly disconnected or if an application already knows the parameters server_host_name and server_port.
|server_host_name||A pointer to the host name of T-Server to be contacted.|
|server_port||The port number.|
|dispatch_function||A pointer to the function that will be called when an event from T-Server arrives.|
|application_name||A pointer to the application name.|
|application_password||A pointer to the string containing the tenant name and the tenant password separated by a slash (/).|
|open_mode||Communication mode (synchronous or asynchronous). Refer to the type TOpenMode for information on the implications of using one mode versus the other.|
> 0 - A local server handle to the specific T-Server; in other words, a unique identifier assigned by T-Library to the connection between a client and T-Server. The handle will be used subsequently to send requests to T-Server throughout this communication session.
< 0 - Error condition. Returned to the application if the communication session with the T-Server could not be established.