TScSFTPServerCloseFileEvent = procedure(Sender: TObject; SFTPSessionInfo: TScSFTPSessionInfo; Data: TObject; var Error: TScSFTPError) of object;


property OnCloseFile: TScSFTPServerCloseFileEvent;



The OnCloseFile event occurs on request from an SFTP client to close an opened handle of a file or directory specified by the Data object.

You can call the DefaultCloseFile method to execute this operation or write your own implementation.



Sender - the object whose event handler is called.
SFTPSessionInfo - contains the information about the current SFTP session.
Data - specifies the information about a closing file or directory as the TScHandle or TScSearchRec object or any user's object. Usually this object is previously returned by the DefaultOpenFile or DefaultOpenDirectory methods, or the OnOpenFile or OnOpenDirectory event handlers.
Error - a parameter to pass the information about an error that can arise when closing a file.


See also


SecureBridge Components, Copyright © 2007-2021 Devart. All Rights Reserved. Provide Feedback Visit Forum Request Support