Connect to the Thereforeâ„¢ Server |
Scroll |
A connected TheSever instance is needed whenever information is read from or written to the database. Therefore, virtually every Thereforeâ„¢ API client application declares a TheServer instance and connects to it before using other classes and methods in the Thereforeâ„¢ API. As most applications need only one server instance, consider declaring your server static/Shared or using the singleton design pattern. The TheServer instance automatically disconnects when the instance is destroyed. It is, however, considered good practice to disconnect when you are done using the server. Here is a general outline for working with the Thereforeâ„¢ Server.
|
Requirements and Assumptions: User "Test" in the domain "Thereforeâ„¢" exists in your Windows Active Directory. If these assumptions do not apply to your system or configuration please replace them with appropriate values when copying the code samples below. |
Connect Property Use the Connected property to check if the server is currently connected.
Connect Using Advanced Options Several overloads are available for the Connect method, allowing you to also specify node IP address and alias and to show a login dialog. Please see the TheServer.Connect overload list for details. |