Hello Charles-Andre Roy , I have a question related to yours (which you successfully solved). Whenever I try to set a string variable to mxd.dataDrivenPages.pageRow.index I get the error: "RuntimeError: Row: Field index does not exist" ... I am trying to export data driven pages to adobe illustrator using the page name. Here's what I have: import arcpy, os, sys, string
from arcpy import env
mxd = arcpy.mapping.MapDocument("CURRENT")
for pageNum in range(1, mxd.dataDrivenPages.pageCount + 1):
mxd.dataDrivenPages.currentPageID = pageNum
arcpy.AddMessage("Exporting PDF Map " + str(pageNum) + " of " + str(mxd.dataDrivenPages.pageCount))
pageName = mxd.dataDrivenPages.pageRow.index
arcpy.mapping.ExportToAI(mxd, r"C:\Dropbox (WSA)\Tucson\PROJECTS ACTIVE\GSA\2014-58 Richfield Travel Routes\Maps\Site_Location\Site_Location_Map\_" + pageName + ".ai")
del mxd I'd appreciate any help! Thanks! Jimmy
... View more