Hi! I'm trying to run python script in ArcGis Pro.
I need to extract information about scale from specific map frame (there are few of them in the layout) in every map in Map Series. I am a new user of Arcgis Pro and python and I stuck 😞
The script I prepared prints out scale info, but it prints always the same value (= the value of scale for map, which is now displayed).
I will be very grateful if someone help me.
"""
import arcpy
aprx = arcpy.mp.ArcGISProject("CURRENT")
l = aprx.listLayouts("nameOfLayout")[0]
if not l.mapSeries is None:
ms = l.mapSeries
if ms.enabled:
pageName = ms.pageRow.OBJECTID
for pageNum in range(1, ms.pageCount + 1😞
ms.currentPageNumber = pageNum
mf_main = l.listElements("MapFrame_Element", "Main Map Frame")[0] ## for "Main Map Frame" I need values from all the maps in map series
scale = mf_main.camera.scale
print(pageNum)
print(scale)
"""