Hi all,
I am fairly new to Python and I have been trying to make a script work-to assign a GC system to a number of shapefiles in a folder.(The GC system is currently Unknown so I cannot use the other tools in batch mode)
I am using Python 2.5 and Arc 9.3.1 but I keep getting errors
( for fc in fcS:
TypeError: 'geoprocessing list object' object is not iterable)
that don't really tip me off about what it s going wrong (newbie)
My code is:
import arcgisscripting
gp = arcgisscripting.create()
gp.workspace = "P:\Proj"
gp.toolbox = "management"
coordsys = "Coordinate Systems/Projected Coordinate Systems/National Grids/British National Grid.prj"
fcs = gp.ListFeatureClasses()
for fc in fcS:
gp.defineprojection(fcS, coordsys)
I am certain there are a lot of errors there, but if anyone can assist with the iteration/listing of the shapefiles in the folder it would be great.
Thanks in advance for any suggestions.
S.