TsgcWSPClient_FilesEvents › OnFileReceivedError

OnFileReceivedError Event

Fires when an error occurs while receiving a file.

Syntax

property OnFileReceivedError: TsgcWSFileErrorEvent;
// TsgcWSFileErrorEvent = procedure(Connection: TsgcWSConnection; const aMessage: TsgcWSMessageFile; const Error: String) of object

Default Value

Remarks

The partial download is discarded and, for qosLevel1/qosLevel2, the server is notified so the upload side gets an OnFileSentError. Common causes are rejection in OnFileReceivedAuthorization, disk-write failures or a size mismatch at completion.

Example

procedure TForm1.oProtocolFileReceivedError(Connection: TsgcWSConnection;
  const aMessage: TsgcWSMessageFile; const Error: String);
begin
  Memo1.Lines.Add('receive error ' + aMessage.FileId + ': ' + Error);
end;

Back to Events