FTP error

G

Guest

Hi all,
I wrote simple FTP client class (using MSDN "template"). It works ok on my
computer, but connection to one server raises this error:
The server returned an address in response to the PASV command that is
different than the address to which the FTP connection was made.

When I set UsePassive to false, another exception throws, but with the same
meaning. I tried IP address to, but with no success.
Does anybody know, what's wrong?


the code is:
FtpWebRequest request = (FtpWebRequest)FtpWebRequest.Create(server);
request.Method = WebRequestMethods.Ftp.ListDirectory;
request.Credentials = new NetworkCredential(userName, password);
//request.UsePassive = false;

FtpWebResponse response = (FtpWebResponse)request.GetResponse();
 
G

Guest

Hi Matthew,

I have experienced exactly the same problem - did you find any solution?

Regards,
Soeren Roemer
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top