cesareo.lorenzo

Exporting multiple Graphs

Discussion created by cesareo.lorenzo on Nov 8, 2012
Latest reply on Nov 9, 2012 by cesareo.lorenzo
Hello everybody,
my colleague and I are trying to save several Graphs contained inside a single *.mxd, but are not capable of doing so iteratively.
On the Esri guide it is written how to point one single Graph and to export it, but how can we automatically save ALL the Graphs inside one project (without having to manually create a list containing hundreds of graph-names)??

This is the Esri script:

Save a graph as a Windows Bitmap image.
# Name: SaveGraph_ExampleBMP.py
# Description: Save a graph as an image

# Import system modules
import arcpy
from arcpy import env

# Set environment settings
env.workspace = "c:/temp"

#Set local variables
graph_grf = "us_pop_2003.grf"
outputFile = "outgraph.bmp"
               
#Execute SaveGraph
arcpy.SaveGraph_management(graph_grf, outputFile, "MAINTAIN_ASPECT_RATIO")

Thank you in advance for your advise!

Cesareo Lorenzo

Outcomes