This is an old revision of the document!
TransferOptions Class
Defines options for file transfers.
Advertisement
Syntax
Namespace: WinSCP
C#
      public sealed class TransferOptions
VB.NET
      Public NotInheritable Class TransferOptions
Constructors
| Name | Description | 
|---|---|
| TransferOptions() | Default constructor. | 
Properties
| Name | Description | 
|---|---|
| string FileMask | File mask. | 
| FilePermissions FilePermissions | Permissions to applied to a remote file (used for uploads only). Use default nullto keep default permissions. | 
| OverwriteMode OverwriteMode | Behaviour when overwriting existing files. This feature is available only in the latest beta release. Possible values are: OverwriteMode.Overwrite(default) to overwrite the existing files.OverwriteMode.Resumeto assume that the existing and smaller file is a remnant of an interrupted transfer and resumes the transfer. SFTP and FTP protocols only.OverwriteMode.Appendto append the source file to the end of existing target file. SFTP protocol only. | 
| bool PreserveTimestamp | Preserve timestamp (set last write time of destination file to that of source file). Defaults to true.When used with Session.SynchronizeDirectories, timestamp is always preserved, disregarding property value, unlesscriteriaparameter isSynchronizationCriteria.NoneorSynchronizationCriteria.Size. | 
| TransferResumeSupport ResumeSupport | Configures automatic resume/transfer to temporary filename. Read-only (set properties of returned TransferResumeSupportinstance) in the latest stable version (settable in the latest beta version). | 
| int SpeedLimit | Limit transfer speed (in KB/s). | 
| TransferMode TransferMode | Transfer mode. Possible values are TransferMode.Binary(default),TransferMode.AsciiandTransferMode.Automatic(based on file extension). | 
Advertisement
Remarks
Use instance of the class with Session.GetFiles, Session.PutFiles or Session.SynchronizeDirectories.