Session.GetFiles Method
Downloads one or more files from remote directory to local directory.
You can have WinSCP generate a code template for Session.GetFiles for you.
The method is quite powerful, but due to a wide range of it uses, its syntax can be cumbersome initially. For specific tasks, consider using convenient alternatives: Session.GetFilesToDirectory and Session.GetFileToDirectory.
Advertisement
Syntax
C#
public TransferOperationResult GetFiles( string remotePath, string localPath, bool remove = false, TransferOptions options = null )
VB.NET
Public Function GetFiles( remotePath As String, localPath As String, Optional remove As Boolean = False,