Hello Ajay,
You need following code to retrieve the list of files
string strResp = String.Empty;
FtpWebRequest request = (FtpWebRequest) WebRequest.Create("ftp://72.3.247.174/");
request.Method = WebRequestMethods.Ftp.ListDirectory;
request.Credentials = new System.Net.NetworkCredential("ppp", "778");
using(FtpWebResponse response = (FtpWebResponse) request.GetResponse())
{
using(StreamReader reader = new StreamReader(response.GetResponseStream()))
{
strResp = reader.ReadToEnd();
}
}
All that will be left is to parse this response and create a dataset. The best demo of this can be found here[
^] on CodeProject.
Regards,