HOW TO
The ArcIMS 9.2 Web ADF contains a full featured ArcIMS API for Microsoft .Net 2.0 Framework. The ArcIMS 9.2 API sends, receives, parses, and processes ArcXML for the user, providing a set of .Net Objects to develop with the user's favorite .Net language.Instructions provided describe the necessary steps to get the old code and applications using ArcIMS .Net Link to work with ArcIMS 9.2 API.
Note:
ArcIMS or ArcGIS Server 9.2 ADF for the Microsoft .Net Framework is built with .Net 2.0 Framework. This article assumes that the ArcIMS or ArcGIS Server 9.2 ADF for the Microsoft .Net 2.0 Platform is installed.
Code:
C#
//using ESRI.ArcIMS.Server;
using ESRI.ArcGIS.ADF.Connection.IMS;
VB.NET
' Imports ESRI.ArcIMS.Server
Imports ESRI.ArcGIS.ADF.Connection.IMS
Code:
// C#
/* Old Code using HTTP Scheme */
ServerConnection connection = new ServerConnection(url);
connection.Scheme = ESRI.ArcIMS.Server.Scheme.HTTP;
connection.URIPort = 80;
connection.ServiceName = serviceName;
string arcxmlRespoonse = connection.Send(arcxmlRequest);
/* New Code using HTTP Connection Type*/
HTTPConnection connection = new HTTPConnection(url);
connection.ServiceName = serviceName;
string arcxmlResponse = connection.Send(arcxmlRequest);
Code:
' VB.NET
' Old Code Imports HTTP Scheme
Dim connection As ServerConnection = New ServerConnection(url)
connection.Scheme = ESRI.ArcIMS.Server.Scheme.HTTP
connection.URIPort = 80
connection.ServiceName = serviceName
Dim arcxmlRespoonse As String = connection.Send(arcxmlRequest)
' New Code Imports HTTP Connection Type
Dim connection As HTTPConnection = New HTTPConnection(url)
connection.ServiceName = serviceName
Dim arcxmlResponse As String = connection.Send(arcxmlRequest)
Code:
// C#
/* Old Code using TCP Scheme */
ServerConnection connection = new ServerConnection();
connection.Scheme = ESRI.ArcIMS.Server.Scheme.TCP;
connection.Host = host;
connection.URIPort = 5300;
connection.ServiceName = serviceName;
string arcxmlResponse = connection.Send(arcxmlRequest);
/* New Code using TCP Connection Type */
TCPConnection connection = new TCPConnection();
connection.Port = 5300;
connection.Host = host;
string arcxmlResponse = connection.Send(arcxmlRequest);
Code:
' VB.NET
' Old Code Imports TCP Scheme
Dim connection As ServerConnection = New ServerConnection()
connection.Scheme = ESRI.ArcIMS.Server.Scheme.TCP
connection.Host = host
connection.URIPort = 5300
connection.ServiceName = serviceName
Dim arcxmlResponse As String = connection.Send(arcxmlRequest)
' New Code Imports TCP Connection Type
Dim connection As TCPConnection = New TCPConnection()
connection.Port = 5300
connection.Host = host
Dim arcxmlResponse As String = connection.Send(arcxmlRequest)
Article ID:000009004
Get help from ArcGIS experts
Download the Esri Support App