vwyeth

Python script to generate xls report

Discussion created by vwyeth on Oct 24, 2013
Latest reply on Oct 24, 2013 by vwyeth
Hello

I wonder if someone can help me please.
I am trying to write a python script which will generate a report in Excel but I need the "Use cell merging" function to be set to true for the final report. I have got the script to generate the report ok but I don't know how to implement to function for cell merging.

import arcpy
mxd = arcpy.mapping.MapDocument(r"C:\test.mxd")
df = arcpy.mapping.ListDataFrames(mxd, "Layers")[0]
lyr = arcpy.mapping.ListLayers(mxd, "Wells", df)[0]
arcpy.mapping.ExportReport(lyr,
                           r"C:\MyRLF.rlf",
                           r"C:\ProjectReport.xls",
                           "EXTENT",
                           extent=df.extent)
del mxd

Is someone able to help me please?

Outcomes