Beispiel #1
0
        public IList<string> ReadLinesFromFtpFile(string file)
        {
            var result = new List<string>();

            var client = new FtpClient(new FtpInfo(_ftpInfo.Address, _ftpInfo.UserName, _ftpInfo.PassWord));
            result = client.ReadLinesFromFtpFile(file).ToList();

            //var client = new SftpClient(getHost(_ftpInfo.Address), _ftpInfo.UserName, _ftpInfo.PassWord);
            //client.Connect();
            //result = client.ReadAllLines(file).ToList();
            //client.Disconnect();
            return result;
        }