script won't recognize input field for polygon to raster - error says : "Field 'x' does not exist within the table"
I join a text file to a polygon feature class. I can list the fields no problem :
for field in theDateFields:
outputname = str(field.name)
have tried the field name and join file field name in python shell as a test - neither work. For example, text file field name of "r19141231" or join file name of "rain1914.txt.r19140101" - neither work.. But again, they will both list in print statement above, but immediately following with tool does not recognize field (dayField):
arcpy.PolygonToRaster_conversion(yearGrid, dayField, outrast)
I can run toolbox Polygon To raster tool and select field and it runs, but script does not. I can even create model with tool loaded (it runs), then export to script, but script won't run - doesn't recognize field. ?????
is there some formatting, parsing, etc I need to do for the field to be recognized in the script?