connectServer - Connect to Access Server
Use this command to establish a connection to Access Server running on the specified server and listening for TCP/IP communications on the specified port number.
This command must be issued before other supported Management Console commands (except the help - command) can be invoked.
From a single command prompt environment, only one connection to an Access Server can be maintained at the same time. You must use the disconnectServer command to end the connection to the Access Server. However, if you have more than one command environment active at the same time, simultaneous connections to multiple Access Server components are possible (one connection per command environment).
Syntax
connectServer(<user>, <password>, <host>, <port>);
Parameters
- <user>
- A Management Console user defined in Access Server.
- <password>
- The password associated with the Management Console user specified through the first parameter (user).
- If no password is associated with the Management Console user,
specify two double quotation marks ("") for this parameter.Note: If this command is included in a script file, the specified password will be encrypted after the script file has been successfully compiled into a batch file that can be executed.
- <host>
- The host name of the server where Access Server is running.
- If Access Server is running on the local system, set this parameter to localhost.
- <port>
- The port number that will be used to establish a connection to Access Server.
Result
None.Example
connectServer(GSMITH, APPLEJUICE, HOST1, 10101);The Management Console user GSMITH with the password APPLEJUICE will establish a connection to Access Server running on the server HOST1, and listening for TCP/IP communications on port number 10101.
connectServer(EAHIGGINS, "", LOCALHOST, 4545);The Management Console user EAHIGGINS will establish a connection to Access Server running on the local system, and listening for TCP/IP communications on port number 4545.
No password is associated with the user EAHIGGINS.