Subject RE: [IBO] Bug? TIB_Query.locate - AbortFetching failing
Author Jason Wharton
Gunther and All,

When dealing with users cancelling operations during fetching, this is a
valuable code snippet that many would be hard pressed to figure out. So,
I'm tossing out on a hunch this will be valuable to some of you.

procedure TForm1.Button1Click(Sender: TObject);
FAGen: integer;
FAGen := MyQuery.FetchingAbortedGen;
if not MyQuery.Locate( 'COL','99999999999', [ lopCaseInsensitive,
lopFindNearest ] ) then
if FAGen <> MyQuery.FetchingAbortedGen then
Showmessage ('Aborted!');

Many I'm sure will have been tempted to use the FetchingAborted: boolean
property but this is insufficient to tell for sure and it wasn't designed
for this purpose anyway.

Hope this helps,
Jason Wharton