TsgcWSPClient_DatasetEvents › OnBeforeDatasetUpdate

OnBeforeDatasetUpdate Event

Fires before any Dataset message from the server is applied locally; set Handled to skip it.

Syntax

property OnBeforeDatasetUpdate: TsgcWSBeforeDatasetUpdateEvent;
// TsgcWSBeforeDatasetUpdateEvent = procedure(Connection: TsgcWSConnection; const JSON: IsgcObjectJSON; var Handled: Boolean) of object

Default Value

Remarks

Umbrella event raised for every incoming Dataset message (new, update, or delete) before the specialized OnBeforeNewRecord / OnBeforeUpdateRecord / OnBeforeDeleteRecord events are evaluated. JSON holds the full server payload, including the Channel that identifies the operation. Set Handled to True to skip all further processing (the specialized Before/After events will not fire and nothing is applied to the Dataset).

Example

procedure TForm1.oProtocolBeforeDatasetUpdate(Connection: TsgcWSConnection;
  const JSON: IsgcObjectJSON; var Handled: Boolean);
begin
  Handled := False;
end;

Back to Events