My issue is trying to retrieve field values inside a for loop:
#userFile - type FeatureLayer
userFile = arcpy.GetParameterAsText(0)
#user selects field from userFile - type Field "obtained from [userFile]"
userField = arcpy.GetParameterAsText(1)
#start cursor
rows = = arcpy.SearchCursor(userFile)
#inside loop, report all values of field [userField]
for row in rows:
arcpy.AddMessage("Analyzing zone " + row.userField)
Python wants userField to be a hard coded value for the field. It won't accept it as a variable set by the user. Any way I can accomplish this?CheersTom