ArcGIS Pro 3.7 API Reference Guide
ArcGIS.Desktop.Mapping Namespace / TopologyLayerCreationParams Class / TopologyLayerCreationParams Constructor / TopologyLayerCreationParams Constructor(Uri)
A System.Uri represents the path or url to a dataset or .lyrx or .lpkx file.
Example

In This Topic
    TopologyLayerCreationParams Constructor(Uri)
    In This Topic
    Creates a parameter object with a System.Uri.
    Syntax
    Public Function New( _
       ByVal uri As Uri _
    )
    public TopologyLayerCreationParams( 
       Uri uri
    )

    Parameters

    uri
    A System.Uri represents the path or url to a dataset or .lyrx or .lpkx file.
    Remarks

    Some sample paths to:

    A Topology in a FileGeodatabase C:\Data\MyFileGDB.gdb\Backcountry\Backcountry_Topology
    A Topology from a SDE C:\Connections\MySDEConnection.sde\Backcountry\Backcountry_Topology

    Example
    Create TopologyLayer with an Uri pointing to a Topology dataset
    {
        var path = @"D:\Data\CommunitySamplesData\Topology\GrandTeton.gdb\BackCountry\Backcountry_Topology";
        var lcp = new TopologyLayerCreationParams(new Uri(path));
        lcp.Name = "GrandTeton_Backcountry";
        lcp.AddAssociatedLayers = true;
        //Note: Needs QueuedTask to run
        var topoLayer = LayerFactory.Instance.CreateLayer<ArcGIS.Desktop.Mapping.TopologyLayer>(lcp, MapView.Active.Map);
    }
    Requirements

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

    ArcGIS Pro version: 3.1 or higher.
    See Also