function Locate( const oTable: TTable; const oField: TField; const sValue: String ): Boolean ; var bmPos: TBookMark ;bFound: Boolean ;begin Locate := FALSE ;bFound := FALSE ;if not oTable.Active then Exit ;if oTable.FieldDefs.IndexOf( oField.FieldName ) < 0 then Exit ;bmPos := oTable.GetBookMark ;with oTable dobeginDisableControls ;First ;while not EOF doif oField.AsString = sValue thenbeginLocate := TRUE ;bFound := TRUE ;Break ;end |
[000368]