Our Products:   CompleteFTP  edtFTPnet/Free  edtFTPnet/PRO  edtFTPj/Free  edtFTPj/PRO
0 votes
2.1k views
in .NET FTP by (120 points)
When using the FTPClient.Dir function to return a string array of all files in a directory, I am only getting 997 of the 1237 files in the folder. I am calling the function like this:

public string [] DirectoryListing()
{
string [] listing = null;
FTPClient ftpListing = Init();

try
{
listing = ftpListing.Dir(".", true);
ftpListing.Quit();

}
catch (Exception e)
{
ftpListing.Quit();
throw new Exception(e.Message);
}
return listing;
}

The timeout is set to 0, and no exceptions are thrown in the process. Do you know of any limitations in the call or the data type which may cause this problem?

I am using an older version of the source code (the app was written last year and has been in production for a year without any issues). The last revision at the top of the FTPClient.cs file is
// Revision 1.4 2004/10/29 14:30:31 bruceb
// BaseSocket changes

and the comment at the top of the FTPClient class says $Revision: 1.14 $.

Mina

1 Answer

0 votes
by (51.6k points)
I don't think there are any limitations of that sort in edtFTPj. Of course, upgrading to the latest version is always advisable. All version are backward compatible.

I suggest logging in with a command-line ftp client, such as ftp.exe on Windows, and doing a file-listing that way. You can then compare the two listings. You could also try using another FTP client application such as FileZilla, which shows the number of files in the status-bar.

- Hans (EDT)

Categories

...