[Visual Basic] Public Function FtpDownloadFile(ByVal remoteHost As String, ByVal remotePath As String, _ ByVal remotePort As Integer, ByVal localFileName As String) As Boolean
[C#] public bool FtpDownloadFile(string remoteHost, string remotePath, int remotePort, string localFileName);
パラメータ
- remoteHost
- DNS スタイルのドメイン名、または IP アドレス
- remotePath
- リモート パスの名称
- remotePort
- IP ポート番号
- localFileName
- ローカル ファイルの名称
戻り値
成功の場合は true 、失敗の場合は false を返します。
解説
FTP プロトコルの場合に有効です。
使用例
[Visual Basic.NET]
Dim Ret As Boolean
'ユーザ名とパスワード
ImageKit.File.FtpCredentials = New NetworkCredential("user", "password")
'パッシブモード接続
ImageKit.File.FtpPassive = True
'ファイルのダウンロード
Ret = ImageKit.File.FtpDownloadFile("www.newtone.co.jp", "test/test.jpg", 21, "c:\test\test.jpg")
[Visual C#.NET]
bool Ret;
//ユーザ名とパスワード
ImageKit.File.FtpCredentials = new NetworkCredential("user", "password");
//パッシブモード接続
ImageKit.File.FtpPassive = true;
//ファイルのダウンロード
Ret = ImageKit.File.FtpDownloadFile("www.newtone.co.jp", "test/test.jpg", 21, @"c:\test\test.jpg");
参照
ImageKit.File メンバ | Newtone.ImageKit.Win.ImageKit