Unit Refreshr

Classes

TRefresher -

Functions

ForceTableRefreshNow - call this if you don't want to wait for Application.
Refresher - check for changed Datasets every .
SetRefreshCheckPeriod - check for changed Datasets every .

Types

TAddDatasetEvent
TRefreshEvent
TRemoveDatasetEvent

Constants

DontRefreshIfAppDeactivated

Variables


Functions


procedure ForceTableRefreshNow;

call this if you don't want to wait for Application.Idle to make sure every Dataset is refreshed:

---------------------------------------------------------------------------


function Refresher: TRefresher;

check for changed Datasets every ... ms

procedure SetRefreshCheckPeriod(Value: Integer);

check for changed Datasets every ... ms (default 1000):

Types


TAddDatasetEvent = procedure (Dataset: TDataset;
                                var CallbackEvent: TBDECallbackEvent;
                                var RefreshEvent: TRefreshEvent) of object

TRefreshEvent = procedure (Dataset: TDataset; var Done: Boolean) of object
Version 2.32 Jul-17-1997 (C) 1997 Christoph R. Kirchner TRefresher manages the refreshes for TSelfRefreshTable. Only one instance of this object gets created and it gets destroyed by an ExitProc. It uses different methods for Delphi 1 and 2, but this is the source for both versions. Delphi 1: Paradox tables only. Delphi >= 2.0: Paradox and dBase tables, Interbase tables get the refresh-event only inside the application, others not tested yet. TSelfRefreshTable uses the Application.OnIdle-event to do the refresh if it is save. Set DontRefreshIfAppDeactivated to true if your application gets confused by self-refreshing tables while the program is not active. The author assumes no liability for damages and disclaims all warranties. See disclaimer in Readme.txt. Please forward any comments or suggestions to Christoph Kirchner at: ckirchner@geocities.com
TRemoveDatasetEvent = procedure (Dataset: TDataset) of object

Constants

DontRefreshIfAppDeactivated = false

set DontRefreshIfAppDeactivated to true, if your application cannot handle refreshes while not activated:

Variables