AnsweredAssumed Answered

What is the correct syntax for my variable?

Question asked by DamianMilne on Feb 2, 2011
Latest reply on Feb 3, 2011 by DamianMilne
Hi, this is possibly the simplest question ever but I simply cannot find the answer anywhere

what is the correct syntax to use for the variable "eachsp" in the following code snippit...

-----------------
specieslist = [1,2,3]
for eachsp in specieslist:

  # Select feature and zoom
  arcpy.SelectLayerByAttribute_management (lyr,"", SpeciesID =  eachsp)   ### this is the problem bit
  df.zoomToSelectedFeatures()
--------------------

Thanks, Damian (Python neub)

Outcomes