NET SFTP Library
SCPGetBinary(String,String) Method
Example 






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

Parameters

localFilePath
A fully qualified path with the file name
remoteFileName
The name of the file to get
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