Nikolay Simeonov wrote: > Hello Francois, > > I'm writing a service and when I try to get the directory FTP1.Dir returns > false. How can I pinpoint the problem and is there a way to figure out why > it's returning false?
There is i.e. property StatusCode and there are events also. You may assign OnDisplay and write to a log file as well. Or use async methods and handle your program flow from within the OnRequestDone-handler. > > I'm using it in non-multithread mode. What's more curious about the code > is the fact it works when I use the same unit from a normal windows > program. And from the service it's crashing. > Do you have any ideas what > could possibly cause the error? Without some more information, it's hard to say anything. > Also a side problem I'm having is: do you know of a simple way to parse > the results from the DIR command into a simple list of filenames, sizes, > attributes (directory or a file) and timestamp? All I'm getting is a text > file and currently I hardcoded the parsing, and that isn't listed anywhere > as best practice, but all I wanted is to get it working quickly and clean > it up later. I've downloaded a unit named ftpcommon.pas somewhere that helps parsing a lot, but I can't find the link at the moment:( Arno Garrels -- To unsubscribe or change your settings for TWSocket mailing list please goto http://www.elists.org/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be
