ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/public/ibx/trunk/examples/isqlmonitor/MonitorFormUnit.pas
Revision: 31
Committed: Tue Jul 14 15:31:25 2015 UTC (8 years, 9 months ago) by tony
Content type: text/x-pascal
File size: 847 byte(s)
Log Message:
Committing updates for Release R1-3-0

File Contents

# User Rev Content
1 tony 31 unit MonitorFormUnit;
2    
3     {$mode objfpc}{$H+}
4    
5     interface
6    
7     uses
8     Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, StdCtrls,
9     IBSQLMonitor;
10    
11     type
12    
13     { TMonitorForm }
14    
15     TMonitorForm = class(TForm)
16     IBSQLMonitor1: TIBSQLMonitor;
17     Memo1: TMemo;
18     procedure FormShow(Sender: TObject);
19     procedure IBSQLMonitor1SQL(EventText: String; EventTime: TDateTime);
20     private
21     { private declarations }
22     public
23     { public declarations }
24     end;
25    
26     var
27     MonitorForm: TMonitorForm;
28    
29     implementation
30    
31     {$R *.lfm}
32    
33     { TMonitorForm }
34    
35     procedure TMonitorForm.IBSQLMonitor1SQL(EventText: String; EventTime: TDateTime);
36     begin
37     Memo1.Lines.Add(DateTimeToStr(EventTime) + ': ' + EventText);
38     {$IFDEF WINDOWS}
39     Application.ProcessMessages;
40     {$ENDIF}
41     end;
42    
43     procedure TMonitorForm.FormShow(Sender: TObject);
44     begin
45     EnableMonitoring;
46     end;
47    
48     end.
49