Connects to the GIS server specified by the machineName.
[Visual Basic 6.0] Sub Connect(
ByVal machineName As String _
[Visual Basic .NET] Public Sub Connect ( _ ByVal machineName As String _ )
[Java] public void connect ( String machineName ) throws IOException, AutomationException
[C++] HRESULT Connect( BSTR machineName );
machineName is a parameter of type BSTR
In order to succesfully connect to the ArcGIS Server using the Connect method on IGISServerConnection, the user account running the application must be a member of the agsusers user group on the ArcGIS Server.
The following VB code shows how to use the IGISServerConnection interface to connect to an ArcGIS Server running on a machine called "melange":
Dim pGISServerConnection As IGISServerConnection
Set pGISServerConnection = New GISServerConnection
The above code assumes that ArcObjects have been installed on the machine which is running the VB applicaiton (by installing the ArcGIS Server Container, ArcEngine, or ArcGIS Desktop).