ArcGIS Pro 3.8 API Reference Guide
ArcGIS.Core.CIM Namespace / CIMInternetServerConnectionBase Class / URL Property
Example

In This Topic
    URL Property (CIMInternetServerConnectionBase)
    In This Topic
    Gets or sets the URL.
    Syntax
    public string URL {get; set;}
    Public Property URL As String
    Example
    Add a WMTS service
    {
      // Create a connection to the WMS server
      var serverConnection = new CIMProjectServerConnection
      {
        URL = "URL of the WMTS service.xml",
        ServerType = ServerType.WMTS,
      };
      var service_connection = new CIMWMTSServiceConnection
      {
        ServerConnection = serverConnection,
        LayerName = "AdminBoundaries", // Specify the layer name you want to add
      };
    
      // Add a new layer to the map
      var layerParams = new LayerCreationParams(service_connection);
      layerParams.MapMemberPosition = MapMemberPosition.AddToBottom;
      var layerCreated = await QueuedTask.Run(() =>
        LayerFactory.Instance.CreateLayer<FeatureLayer>(layerParams, map));
    }
    Requirements

    Target Platforms: Windows 11 Home, Pro, Enterprise (64 bit)

    ArcGIS Pro version: 3.0 or higher.
    See Also