Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have to loop through some folders which may contain *.mxd files and change their coordinate system. I already found this piece of Python which should do the trick for ArcGIS 10.x (from here):

prjFile = prjPath + "/" + "NAD 1983 UTM Zone 10N.prj"
sr = arcpy.SpatialReference(prjFile)
for DF in MAP.ListDataFrames(MXD):
    DF.spatialReference = sr

However, it looks like there is nothing similar to the arcpy.mapping module in 10 available in 9.3. I need to access the MXD file and then the dataframe(s) it contains, in order to change the coordinate system.

I could not find anything useful so far, although I assume that other people may have similar issues.

My question therefore, is there any (simple) workaround to this using Python (arcgisscripting) in ArcGIS 9.3?

share|improve this question
arcpy.mapping was not available until 10.0 but I think you should be able to use arcgisscripting to access the Project and Project Define tools as appropriate and Python os module to listfiles to find spatial data in your folders. – PolyGeo Mar 6 '13 at 23:43
@PolyGeo : the tools Project and Define Projection both do not work here, as I only have to change the CS in the dataframe - I do not want to re-project any data. – David Mar 6 '13 at 23:49
Had assumed you must have been going on to export data in the coordinate system of the data frame but if you are only looking at on-the-fly for display then I think you are at a 9.3 dead end. – PolyGeo Mar 7 '13 at 7:42
The bigger picture is that we are reprojecting our whole data in another process. However, our users have their MXDs which still link to the same data (with the now new projection) but the data frames will still have the old projection. Therefore I want to change the coordinate systems in the MXD files. – David Mar 7 '13 at 19:29
up vote 1 down vote accepted

Although very easy to do at 10.0, I do not believe it is possible to use Python to update the Coordinate Systems of Data Frames in any straightforward manner at 9.3 and earlier.

Only approaches I can suggest are:

  1. Leave doing this until you can upgrade to 10.x
  2. Look at calling ArcObjects from Python.
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.