RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TSQLConnection.SetTraceEvent Method

Associates the SQL connection with a callback function that executes for every SQL command passed to or from the server.

Pascal
procedure SetTraceEvent(Event: TDBXTraceEvent);
C++
__fastcall SetTraceEvent(TDBXTraceEvent Event);

Call SetTraceEvent to assign a callback that responds every time an SQL command passes between the associated dbExpress driver and the database server. The callback function becomes the value of the TraceCallbackEvent property. 

Event is the TDBXTraceEvent event that is called for every message that passes between the dbExpress driver and the SQL server.

Tip: Read the TraceCallbackEvent property to determine whether a callback is already assigned before calling the SetTraceEvent method. That way, you can avoid interfering with an existing callback when assigning a new one.
 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!