AnsweredAssumed Answered

Issue with Esri training, Using Python in ArcGIS Desktop 10.

Question asked by LeonelDeleon on Nov 10, 2014
Latest reply on Dec 10, 2014 by shellywerner


     I am currently trying to complete an esri course for my gis class  entitled "Using Python in ArcGIS Desktop 10" but i keep running into a problem. On the 6th step of the exercise where it tells me to upload and complete the missing portion of a .cal file into a field calculator. The field that i am uploading this .cal file is a text data type in the attribute table for the schools layer. Once uploaded, I add the missing portion of the script as instructed in the course so it looks like the following.

def lable(name, type):

if type == " HIGH":

  return name + "HS"

elif type == "MIDDLE":

  return name + "MS"

elif type == "ELEMENTARY":

  return name + "ELEM"

     I made sure that the indentations were correct and that the parser was set to python every time i clicked ok on the field calculator. I even uploaded a completed version of the script from another .cal file that was included with the the course data itself and keep receiving the same message that states that there was a failure during the process and to refer to the geoprocessing results window. The results state that there has been an error 9999. I tried looking through the logs to see anything that could be wrong, but I cant find it. I am using ArcGIS 10.2.2 Advanced(ArcInfo) single use.