NET SFTP Library
SCPGetBinary(String,String,IFireProgress) Method
Example 






KellermanSoftware.NetSFtpLibrary Namespace > SFTP Class > SCPGetBinary Method : SCPGetBinary(String,String,IFireProgress) Method
A fully qualified path with the file name
The name of the file to get
Monitor the progress
Download a file using SCP
Syntax
'Declaration
 
Public Overloads Sub SCPGetBinary( _
   ByVal localFilePath As System.String, _
   ByVal remoteFileName As System.String, _
   ByVal fireProgress As IFireProgress _
) 
'Usage
 
Dim instance As SFTP
Dim localFilePath As System.String
Dim remoteFileName As System.String
Dim fireProgress As IFireProgress
 
instance.SCPGetBinary(localFilePath, remoteFileName, fireProgress)
public void SCPGetBinary( 
   System.string localFilePath,
   System.string remoteFileName,
   IFireProgress fireProgress
)
public procedure SCPGetBinary( 
    localFilePath: System.String;
    remoteFileName: System.String;
    fireProgress: IFireProgress
); 
public function SCPGetBinary( 
   localFilePath : System.String,
   remoteFileName : System.String,
   fireProgress : IFireProgress
);
public: void SCPGetBinary( 
   System.string* localFilePath,
   System.string* remoteFileName,
   IFireProgress* fireProgress
) 
public:
void SCPGetBinary( 
   System.String^ localFilePath,
   System.String^ remoteFileName,
   IFireProgress^ fireProgress
) 

Parameters

localFilePath
A fully qualified path with the file name
remoteFileName
The name of the file to get
fireProgress
Monitor the progress
Remarks
https://blogs.oracle.com/janp/entry/how_the_scp_protocol_works
Example
SFTP sftp = new SFTP(); //Trial Mode            
//SFTP sftp = new SFTP("place user name here", "place license key here");
 
// set the name of the SSH server( its URL )
sftp.HostAddress = "some.sftp.server.com"; // replace with your SFTP server
sftp.UserName  = "anonymus"; // replace with your user name
sftp.Password = "user@mail.com"; // replace with your password
 
sftp.SCPGetBinary("a.txt", "a.txt");
Dim sftp As New SFTP() 'Trial Mode
'Dim sftp = New SFTP("place user name here", "place license key here")
 
' set the name of the SSH server( its URL )
sftp.HostAddress = "some.sftp.server.com" ' replace with your SFTP server
sftp.UserName = "anonymus" ' replace with your user name
sftp.Password = "user@mail.com" ' replace with your password
 
sftp.SCPGetBinary("a.txt", "a.txt")
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

SFTP Class
SFTP Members
Overload List