Our Products:   CompleteFTP  edtFTPnet/Free  edtFTPnet/PRO  edtFTPj/Free  edtFTPj/PRO
0 votes
12.3k views
in .NET FTP by
Anything I ever try to run through the .Put method after obtaining a connection and logging in throws a System.FormatException.

"Input string was not in a correct format."

I went as far as to go into the code posted at

http://www.ondotnet.com/pub/a/dotnet/2004/05/10/ftpdotnet.htm?page=last&x-order=date

by Jesse Liberty, and received the same exact error - failing on the .write method of the stream.

I can't seem to find in here that ANYBDOY else has had this problem, but I'm doing something so simple that I can't fathom what's going on. I ran the example client from the above article verbatim and received the same result.

Can anybody help? Thanks. :)

13 Answers

0 votes
by (280 points)
The transfer is in binary, and it does not happen every time, just seems very sporatic. I've changed my process so that I can use your logging on my production enviornment, I'll have a log to email to you as soon as the issue happens again.

Thanks for your quick response.

Albert
0 votes
by (162k points)
Set the FTPConnection property KeepAliveTransfer to false

Your messages are getting out of order - the reply to PASV should be

227 Entering Passive Mode (xx,xx,xx,xx,xx,xx).

but you are getting

200 noop

The reply to PASV is parsed to obtained the IP address & port number to connect to, but it isn't there.
0 votes
by (280 points)
I'll give that a shot.

Thanks again for your quick response.

Albert

Categories

...