RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TFieldList.Find Method

Returns a field component given the field name.

Pascal
function Find(const Name: WideString): TField; reintroduce;
C++
__fastcall TField Find(const BSTR Name);

Call Find to determine if a specified field component is referenced in the TFieldList object. FieldName is the name of the field for which to search. If Find finds a field with a matching name, it returns the TField component for the specified field. Otherwise it returns nil (Delphi) or NULL (C++).

Note: Find differs from the FieldByName method only when the named field is not in the list. When the field is not found, Find returns nil (Delphi) or NULL (C++), while FieldByName raises an exception.
 

Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
What do you think about this topic? Send feedback!