I'm hoping someone can tell me whats going on with the below bit of code. I keep getting the errorAttributeError: 'float' object has no attribute 'setValue'and I'm not sure how to resolve it. Can someone please explain? NONFLOOD = "GRIDfield"
NF1curs = arcpy.UpdateCursor(BuildingGridSelect)
for nf1row in NF1curs:
nf1val = nf1row.getValue(NONFLOOD)
if nf1val < 0:
nf1val.setValue(NONFLOOD, 0)
NF1curs.updateRow(nf1row)
nf1val may result in a negative float value (e.g. -2.32076), but what is the correct syntax to update the value to 0?