I realize this question has been asked in its basic form before, but I've tried a lot of code samples on answers posed to similar questions on this site to no avail.
I'd like to create a new field in my attribute table (Label) that uses the VBScript comparison operators in Field Calculator to define the value based on text values of a field within the table (STATUS).
If the field "STATUS" is "USFS", I want "Label" to equal "USFS".
If the field "STATUS" is not "USFS", I want the "Label" to equal "Other".
However, I always get a return value of "Other". Here is the pre-logic script code I'm using:
dim n if [STATUS] = USFS Then n = "USFS" elseif [STATUS] <> USFS Then n = "Other" end if