Skip to content

TFields.IndexOf

Return the index of a field instance.

Declaration

Source position: db.pas line 1368

public 
function TFields.IndexOf(Field: TField) : LongInt;

Description

IndexOf scans the list of fields and returns the index of the field instance in the list (it compares actual field instances, not field names). If the field does not appear in the list, -1 is returned.

See also

Name Description
TFields.FieldByName Find a field based on its name.
TFields.FieldByNumber Search field based on its fieldnumber.
TFields.FindField Find a field based on its name.