Re: ADOQuery async operation



Oops. Needed to add eoAsyncFetch.

Sorry to bother.

....Andy
Andy Stephenson wrote:
Hi,
I am using a TADOQuery and have set ExecuteOptions to [eoAsyncExecute], and have set ADOQuery.OnFetchComplete := MyHandler.

However, when I set ADOQuery.Active := true after setting the SQL, my handler never fires.

All of this happens in a thread, and the ADOConnection, ADOQuery are created in the .Execute of the thread before my while (not Terminted) loop. All works as expected if I use sync calls, but I want to let other threads in whilst waiting for the results.

So, working on the assumption I have missed something, does anyone know of any articles on using ADOQuery asynchronously? Google is not proving to be of help so far.

Thanks,

Andy
.