Page 1 of 1

Incomplete listing of files using NextFTPDirectoryEntry

Posted: Tue Sep 18, 2012 5:45 pm
by calixarene
When I test to use the NextFTPDirectoryEntry(#Ftp) command to access a server (Hylafax server using port 4559), I found that the file listing return in the server folder is incomplete. Only three files are reported whereas the server has five. I have used the FTPDirectoryEntryRaw(#Ftp) command to examine the directory instead of FTPDirectoryEntryName(#Ftp) but the result are the same. Is it because the newline character in the server is #LF and I need to do something in the window compiler option?

I have used other FTP program to access this server without missing any file in the folder.

One more question. I would like to clarify the use of the command NetworkClientEvent(Connection) and ReceiveNetworkData(Connection, *DataBuffer, DataBufferLength). When a file immediately follow a binary data section is received. Will the ReceiveNetworkData() command knows this is happening and return zero just before the file section, then fire a NetworkClientEvent() with result value = #PB_NetworkEvent_File.

Thanks in advance.

I am still a newbie in purebasic :oops:

Re: Incomplete listing of files using NextFTPDirectoryEntry

Posted: Tue Sep 18, 2012 10:03 pm
by jassing
Yea; I've had this problem on countless servers -- the general input I got was to use the raw function -- didn't help -- in the end, I had to code it using winapi's.

For me, the built in examine functions returned (about) 'every other file' - but if I knew the names of all files, I could download them w/o problem.