ArcGIS Pro 3.8 API Reference Guide
ArcGIS.Desktop.Presentations Namespace / MapPresentationPage Class / SetCamera Method / SetCamera(IEnumerable<Layer>) Method
A list of layers.

In This Topic
    SetCamera(IEnumerable<Layer>) Method
    In This Topic
    Sets the map page extent using the extent of multiple layers. This method must be called on the MCT. Use QueuedTask.Run.
    Syntax
    public void SetCamera( 
       IEnumerable<Layer> layers
    )
    Public Overloads Sub SetCamera( _
       ByVal layers As IEnumerable(Of Layer) _
    ) 

    Parameters

    layers
    A list of layers.
    Exceptions
    ExceptionDescription
    This method or property must be called within the lambda passed to QueuedTask.Run.
    Requirements

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

    ArcGIS Pro version: 3.5 or higher.
    See Also