I am trying to save the following python script as a tool to be incorporated into modelbuilder within Pro:
mxd = arcpy.mapping.MapDocument(r"C:\Project\Project.mxd")
It works in ArcMap but I'm not sure how to do it in Pro since it does not use .mxd files.
How can I access the map document in Pro and run a tool that traditionally uses an .mxd?
ArcGIS Pro works with projects (.aprx). You can import your current MXD to a blank aprx. Ex:
aprx = arcpy.mp.ArcGISProject(r"C:\Projects\blank.aprx") aprx.importDocument(r"C:\Projects\YosemiteNP\Documents\Yosemite.mxd")
You can then export the layout to PNG: