TsgcWSPClient_Files › Events › OnException
Fires when an unhandled exception is raised inside the subprotocol worker or QoS timer thread.
property OnException: TsgcExceptionEvent;
// TsgcExceptionEvent = procedure(Connection: TsgcWSConnection; E: Exception) of object
—
Receives the original Exception object so you can log it or take corrective action (reconnect, retry). The subprotocol continues running after the handler returns; the exception is not propagated to the caller.
procedure TForm1.oProtocolException(Connection: TsgcWSConnection; E: Exception);
begin
Memo1.Lines.Add('exception: ' + E.ClassName + ' ' + E.Message);
end;