ArcGIS Pro 3.1 API Reference Guide
ArcGIS.Desktop.Mapping Namespace / MappingExtensions Class / CanSetActiveTopology Method / CanSetActiveTopology(Map,String) Method
The map to set the topology.
the geodatabase topology name or "Map" if map topology proeprties is required.
Example

In This Topic
    CanSetActiveTopology(Map,String) Method
    In This Topic
    Gets if the active topology can be set. Topologies are only supprted for 2D non-stereo maps.
    Syntax
    public static bool CanSetActiveTopology( 
       Map map,
       string topologyName
    )
    Public Overloads Shared Function CanSetActiveTopology( _
       ByVal map As Map, _
       ByVal topologyName As String _
    ) As Boolean

    Parameters

    map
    The map to set the topology.
    topologyName
    the geodatabase topology name or "Map" if map topology proeprties is required.
    Remarks
    Use "Map" to set the ArcGIS.Desktop.Editing.MapTopologyProperties for the map. Use the geoddatabase topology name to set the ArcGIS.Desktop.Editing.GeodatabaseTopologyProperties for the map.
    Example
    Set the current topology by name
    if (map.CanSetActiveTopology("TopologyName"))
    {
      await map.SetActiveTopologyAsync("TopologyName");
    }
    
    Requirements

    Target Platforms: Windows 11, Windows 10

    ArcGIS Pro version: 3.1 or higher.
    See Also