ArcGIS Pro 3.3 API Reference Guide
ArcGIS.Desktop.Reports Namespace / ReportElementFactory Class / CreateMapFrame Method
IElementContainer
Envelope

In This Topic
    CreateMapFrame Method (ReportElementFactory)
    In This Topic
    Creates a mapFrame element on a report from an envelope geometry. This method must be called on the MCT. Use QueuedTask.Run.
    Syntax
    Public Function CreateMapFrame( _
       ByVal elementContainer As IElementContainer, _
       ByVal envelope As Envelope, _
       ByVal map As Map, _
       ByVal mapFrameName As String _
    ) As MapFrame

    Parameters

    elementContainer
    IElementContainer
    envelope
    Envelope
    map
    mapFrameName
    Exceptions
    ExceptionDescription
    This method or property must be called within the lambda passed to QueuedTask.Run.
    Invalid report section.
    Invalid report.
    Element extents outside section.
    Cannot add map frame to this section type.
    Failed to create map frame.
    Requirements

    Target Platforms: Windows 11, Windows 10

    ArcGIS Pro version: 3.3 or higher.
    See Also