Skip to content

Instantly share code, notes, and snippets.

using System;
using System.IO;
using System.Net;
using System.Net.FtpClient;
using System.Threading.Tasks;
namespace FtpClientSample
{
class Program
{
@shahzadusman
shahzadusman / gist:c6e69d4455d064012054
Created October 6, 2014 15:52
Problem in executing code completly
First line is not returning result so it is not executing remaining three line please help me solve this problem.
string fileName = ftpFileManager.DownloadFileAsync("products2.dat", "foo").Result; // Not returning result
Console.WriteLine(fileName); // Not executing
Console.WriteLine("Done"); // Not executing
Console.ReadLine(); // Not executing