//FTP取檔
FTPSClient ftp = new FTPSClient();
try
{
ftp.Connect(Other.FTP.Server, new NetworkCredential(Other.FTP.Account, Other.FTP.Password), ESSLSupportMode.ClearText);
ftp.SetCurrentDirectory(ftpSrcPath); ftp.GetFiles(localDestPath, string.Format("*.{0}", Other.FTP.Layout), EPatternStyle.Wildcard, false);
ftp.DeleteFile(ftpSrcPath);
}
catch (Exception ex)
{
errmsg = ex.Message;
}
Console.WriteLine(errmsg);
Console.ReadLine();
ftp.Close();紅色字體段報錯(提示:沒有這個文件或目錄),路徑是對的,請問是不是還需要設置其他什麽,求解!
FTPSClient ftp = new FTPSClient();
try
{
ftp.Connect(Other.FTP.Server, new NetworkCredential(Other.FTP.Account, Other.FTP.Password), ESSLSupportMode.ClearText);
ftp.SetCurrentDirectory(ftpSrcPath); ftp.GetFiles(localDestPath, string.Format("*.{0}", Other.FTP.Layout), EPatternStyle.Wildcard, false);
ftp.DeleteFile(ftpSrcPath);
}
catch (Exception ex)
{
errmsg = ex.Message;
}
Console.WriteLine(errmsg);
Console.ReadLine();
ftp.Close();紅色字體段報錯(提示:沒有這個文件或目錄),路徑是對的,請問是不是還需要設置其他什麽,求解!
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货