1

When inspecting features in my featureclass, I am checking to see if a feature has an OID using the HasOID property. Even though the feature(s) clearly has an ID on visual inspection (via ArcMap), the property is returning false. When inspecting the value for the objectID it is reporting nothing. The featureclass is stored in an SDE instance on SQL Server. The ObjectID exists in the featureclass and is populated when viewing in ArcMap.

0

The ObjectID wasn't found in my feature, because when querying the featureclass prior to viewing the features, I removed the objectid from the subfields list. Added it back in and it worked fine.

Not the answer you're looking for? Browse other questions tagged or ask your own question.