FTP Error 550
Hello... I'm a newbie programming in .NET C# having trouble uploading files to an FTP Server. I use the background worker to upload the files.
What the program does is just upload files selected by the user to a static ftp server.
The first selected files are sent well, but when the program finishes the first files, I give the user the option to go back and select some more files to send, and then it's when the 550 error happens.
I can't figure why this happens because the filename is right and doesn't exist in the server; the path is right, the user has access.
The function that uploads is pasted in the following URL:
http://www.wilcob.com/Wilco/Pastecode/5133/showpaste.aspx
I could use some help, and I welcome all attempts.
Thanks.
[777 byte] By [
neskk] at [2008-1-9]
550 means "Requested action not taken", and it can be caused by access permissions, but also other causes such as invalid path or file name.
Does the server send any accompanying text along with the 550 error code to give more details as to the problem? Also you might try a network sniff comparing the first successful upload with the first unsuccessful upload to see what you're doing differently.
Lance
http://geekswithblogs.net/Lance
The FTP server doesn't return anything more besides the 550 Error.
The Path is valid, I've tested it, and the file doesn't exist.
If I could see the FTP log maybe I could see the problem but I don't know how...
I'm not trying to download it... I'm trying to upload it!
Nobody had a look at the code...
Trying to get the log now to see if I can understand the error.
You can copy/paste the results from the trace log and we'll take a look.
If you're uploading, then 550 means that the path is not correct.
I looked at your code and this line jumped at me:
string uri = "ftp://" + ftpServerIP + "/" + ftpPath + filename;
Does ftpPath end with "/"? If not you have to add it the way add after ftpServerIP.
Mariya
Finally found the problem. Can't understand how I couldn't see it in the first place.
The problem was indeed the ftpPath but it was not the slashes. It was an concatenation that wasn't on the code I've posted.
Now the problem is solved. Thank you all.