I want to assign numbers to a certain types of building and I need to use field calculator. I tried many different versions of this and I still can't find what's wrong. Could you tell me where do I make a mistake?
Your python syntax is not correct, try:
def myFunc(typ, oby): if typ == 'D': return 'Z' else: return '25'
Here is a working if/then statement in VBS.
For your code, I would think something like this:
Dim result if [TYP] = "D" then result = "Z" else result = "25" end if
obyv = result
Looks like you used "=" rather than "==".
def countRows(rowcount): import arcpy if %rowcount% == 0: return "false" else: return "true"