chrisjcantire

new to python...

Discussion created by chrisjcantire on Mar 22, 2013
Latest reply on Mar 25, 2013 by chrisjcantire
new to python AND new to arcgis 9.3, coming from mapbasic background.

I'm learning some python for scripting in 9.3, and come up with this:

import arcgisscripting

# create the geoprocessor object
gp = arcgisscripting.create(9.3)

gp.workspace = "I:\PDtest"

# process
gp.PointDistance_analysis("stores.shp", "competitors.shp", "output.dbf", "1000 meters")

...it runs fine, but, what if I wanted to have a user input the names etc into a text box before this continued?  like so:

workspace_entry = raw_input('please enter path to workspace')
layer1 = raw_input('please enter first layer')
layer2 = raw_input('please enter second layer')

or something like that; it crashes when I try, but still very new to all of this...

thanks,

cj

Outcomes