issue was with the filename winscp uses to delete the file...
winscp issues a dele command with the filename as a parameter - if the file is in /folder1/temp/file.txt, then a parameter is "/folder1/temp/file.txt". Using Microsoft FTP client if you cd to the same folder and issue a dele file.txt, the parameter passed is "file.txt". Using MS FTP client if I issue the same command as winscp does (dele /folder1/temp/file.txt) - this results in the the following in the winscp log:-
> 2010-04-22 14:09:08.767 DELE /test/download/HRMS_Australia/testfile.dat
< 2010-04-22 14:09:08.830 450 Deletion failed
Seems to be a problem specific to WSFTP Server - I'm only paraphrasing the WSFTP support guys email that he sent back to me:-
<partial log entry from wsftp server:-
Line 133663: 2010-04-22 13:08:51 User.Error commsgateway1 Apr 22 14:08:53 LAZYORANGE FTP: Failed to remove /test/download/HRMS_Australia/testfile.dat <Host=ftp4.kewill.net, SessionID=09606658, Listener=x.x.x.x:21, Client=x.x.x.x:4483, User=username><Command=DELE, Parameters=/test/download/HRMS_Australia/testfile.dat, Error=450>
This is showing that they are unusually using the full path when they delete the file, the FTP server can either hide or show the root of the path, in this case the root is folder12, so the real path is infact /folder12/test/download/HRMS_Australia/testfile.dat, so I have switch this account to show the root folder, so you will now see the full path, this will fix the issue.
Hope the above makes sense??? To the developer(s) of Winscp - would it be possible to include an option to not sent the full file path (I tried it in console mode, but winscp seems to insist on sending the full path of the file to be deleted)...?