[GIS] Changing page layout from portrait to landscape using ArcPy with ArcMap

arcgis-10.0arcpylayouts

I need my script to access the Page Orientation property of the current MXD, and switch it from portrait to landscape (or back).

I've looked through the ArcGIS 10 arcpy and arcpy.mapping documentation, and haven't had any luck.

Does anyone know how to do this?

Best Answer

Sadly the answer is no. sorry

Even from ESRI Staff:

"There are currently no properties to read/change the page size using arcpy.mapping. As a workaround, you could create MXDs for each page size and oreintation you needed. The closest example I can think of is the "Creating a map book with facing pages" help topic. It doesnt use different pages sizes, however, it does use two MXDs, one for right facing pages, one for left facing pages. In your case, you may have one MXD for letter size, and one MXD for legal size, as an example."

http://forums.arcgis.com/threads/10361-change-Page-and-Print-Setup-from-ArcPy?p=32342#post32342

Possible Workaround is:

http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//00s90000002p000000.htm