ArcObjects Library Reference  (GeoDatabase)    

IRow.OID Property

The OID for the row.

[Visual Basic 6.0]
Property OID As Long
[Visual Basic .NET]
Public ReadOnly Property OID As Integer
public int OID {get;}
public  getOID (
    Long OID
  long* OID


OID [out, retval]

  OID is a parameter of type long

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.


Gets the OID for a row in a table that has a unique Object ID, such as tables registered with the geodatabase.


    public void IRow_get_OID(IRow row)
        //check if a row has an OID
        if (row.HasOID)
            // do something...
            Console.WriteLine("The row has an OID of {0}", row.OID);

[Visual Basic 6.0]


If pRow.HasOID Then
  Debug.Print pRow.OID
End If

See Also

IRow Interface