ArcGIS Pro 2.7 API Reference Guide
CreateMap(Uri) Method

ArcGIS.Desktop.Mapping Namespace > MapFactory Class > CreateMap Method : CreateMap(Uri) Method
The uri to the package or file
Creates a new Map in the project from a map package or file Uri This method must be called on the MCT. Use QueuedTask.Run.
Syntax
public Map CreateMap( 
   Uri dataUri
)
Public Overloads Function CreateMap( _
   ByVal dataUri As Uri _
) As Map

Parameters

dataUri
The uri to the package or file

Return Value

Exceptions
ExceptionDescription
This method or property must be called within the lambda passed to QueuedTask.Run.
Remarks
To open a map, use ProApp.Panes.CreateMapPaneAsync method.
Requirements

Target Platforms: Windows 10, Windows 8.1

See Also

Reference

MapFactory Class
MapFactory Members
Overload List