I need to run a query in a thread and want to display each record as it is processed.
The problem is that the TOracleQuery is running in a DataModule and the results will be displayed on a form (or other Display object) so I am wondering what is the best way to pass the information to the display vehicle in a way that is both loosely coupled and thread safe.
So two issues:
1. How to pass the data row around there does not appear to be a DataRow class (like Java).
2. If I roll my own mini-class to hold the row of data (easy enough for me, if I have to) how do I make sure that the data reaches the display object within the Thread Synchronization that OnThreadRecord initiates.
The problem is that the TOracleQuery is running in a DataModule and the results will be displayed on a form (or other Display object) so I am wondering what is the best way to pass the information to the display vehicle in a way that is both loosely coupled and thread safe.
So two issues:
1. How to pass the data row around there does not appear to be a DataRow class (like Java).
2. If I roll my own mini-class to hold the row of data (easy enough for me, if I have to) how do I make sure that the data reaches the display object within the Thread Synchronization that OnThreadRecord initiates.