我可以下載一個沒有任何FTP問題的文件,但是不能從FTP上傳一個文件到本地,我已經把它改成了黑色和正斜線,仍然有同樣的錯誤。ftp上傳錯誤:「給定路徑的格式不被支持」
string _ftpURL = @"192.168.0.134";
string _UserName = "root"; //User Name of the SFTP server
string _Password = "porter"; //Password of the SFTP server
int _Port = 2222; //Port No of the SFTP server (if any)
string _ftpDirectory = "/home/root/systools/WM"; //The directory in SFTP server where the files will be uploaded
string LocalDirectory = " E:\\charan\\final test\\WebMobility.db"; //Local directory from where the files will be uploaded
Sftp Connection = new Sftp(_ftpURL, _UserName, _Password);
Connection.Connect(_Port);
**Connection.Put(LocalDirectory, _ftpDirectory);**
Connection.Close();
謝謝fnupp,那是錯誤... – 2014-09-25 09:59:19