ArcGIS Pro 3.2 API Reference Guide
ArcGIS.Desktop.Mapping Namespace / Map Class / SetClipGeometry Method / SetClipGeometry(Polygon,IEnumerable<Layer>,IEnumerable<ElevationSurfaceLayer>,CIMLineSymbol) Method
The clip polygon
A list of layers to exclude from the clipping. Pass null if no layers are to be excluded from the clipping operation.
A list of elevation surfaces to exclude from the clipping. Pass null if no elevation surfaces are to be excluded from the clipping operation.
The border symbol to use or null

In This Topic
    SetClipGeometry(Polygon,IEnumerable<Layer>,IEnumerable<ElevationSurfaceLayer>,CIMLineSymbol) Method
    In This Topic
    Set map clipping to the provided clip polygon. Specify layers or elevation surfaces to be excluded from the clipping operation. This method must be called on the MCT. Use QueuedTask.Run.
    Syntax

    Parameters

    clipPolygon
    The clip polygon
    excludeLayers
    A list of layers to exclude from the clipping. Pass null if no layers are to be excluded from the clipping operation.
    excludeSurfaces
    A list of elevation surfaces to exclude from the clipping. Pass null if no elevation surfaces are to be excluded from the clipping operation.
    border
    The border symbol to use or null
    Exceptions
    ExceptionDescription
    This method or property must be called within the lambda passed to QueuedTask.Run.
    clipPolygon cannot be null
    "Excluded layers must be part of this map.";
    Remarks
    If the clip polygon is not in the spatial reference of the map it will be projected. Clipping will be set to ArcGIS.Core.CIM.ClippingMode.CustomShape. If the border symbol is null then the existing ArcGIS.Core.CIM.CIMMap.ClippingAreaBorderSymbol will be used. If ClippingAreaBorderSymbol is also null then a default line symbol will be assigned.
    Requirements

    Target Platforms: Windows 11, Windows 10

    ArcGIS Pro version: 3 or higher.
    See Also