AnsweredAssumed Answered

ExportToJpeg Resolution Problem

Question asked by stevenoliver13 on Sep 8, 2017
Latest reply on Sep 10, 2017 by stevenoliver13

Im still pretty new to Python, pretty much an infant. I put together a script for bulk exporting DDP to .jpg with world file, and it works fine, except for one problem. the resolution only exports at the default, 96 dpi. When I put an interger in the resolution, it doesnt change from 96 dpi.I would like it to be a little higher. Everything I have seen in others scripts, it seems to work fine and it matches the syntax of ExportToJpeg? I have checked over many options from different answers, including making it a constant, different spacing, etc., etc. My question is what am I missing? 


The script is as follows:


...import arcpy

mxd = arcpy.mapping.MapDocument("CURRENT")
df = arcpy.mapping.ListDataFrames(mxd)[0]

for pageNum in range(1, mxd.dataDrivenPages.pageCount + 1):
   mxd.dataDrivenPages.currentPageID = pageNum
arcpy.mapping.ExportToJPEG(mxd, r"C:\Insert\File\Path\Here\{}.jpg".format(pageNum), df, df_export_width=1600, df_export_height=1200, resolution=300, world_file=True)
del mxd


Thanks for any help!