Description
Disconnects a client application from a server application.
Applies to
Connection objects
Syntax
connection.DisconnectServer ( )
Argument |
Description |
---|---|
connection |
The name of the Connection object used to establish the connection you want to delete |
Return value
Long.
Returns 0 if it succeeds and one of the following values if an error occurs:
50 -- Distributed service error
52 -- Distributed communications error
53 -- Requested server not active
54 -- Server not accepting requests
55 -- Request terminated abnormally
56 -- Response to request incomplete
57 -- Not connected
62 -- Server busy
Usage
After disconnecting from the server application, the client application needs to destroy the Connection object.
DisconnectServer causes all remote objects and proxy objects created for the client connection to be destroyed.
Examples
In this example, the client application disconnects from the server application using the Connection object myconnect:
myconnect.DisconnectServer() destroy myconnect
See also
ConnectToServer (obsolete)