Post a reply

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

manfromregina1

Re: Transfer Result Check throws "File Already exists. Delete existing file" exception...

Turns out this issue is not WinSCP related but a firewall issue with the server. Please ignore this post. Thanks for your quick follow up.

martin wrote:

Please attach a full session log file showing the problem (using the latest version of WinSCP).

To generate the session log file, set Session.SessionLogPath. Submit the log with your post as an attachment. Note that passwords and passphrases not stored in the log. You may want to remove other data you consider sensitive though, such as host names, IP addresses, account names or file names (unless they are relevant to the problem). If you do not want to post the log publicly, you can mark the attachment as private.
martin

Re: Transfer Result Check throws "File Already exists. Delete existing file" exception...

Please attach a full session log file showing the problem (using the latest version of WinSCP).

To generate the session log file, set Session.SessionLogPath. Submit the log with your post as an attachment. Note that passwords and passphrases not stored in the log. You may want to remove other data you consider sensitive though, such as host names, IP addresses, account names or file names (unless they are relevant to the problem). If you do not want to post the log publicly, you can mark the attachment as private.
manfromregina1

Transfer Result Check throws "File Already exists. Delete existing file" exception...

Hello,

We are using the WinSCP .NET library (which came with version 5.5.3) and it was working was great for us until couple of days ago when we starting getting these exceptions during file upload. The thing is the file does upload successfully by calling the putfiles method below. However, the subsequent call to check the transfer result throws an exception stating the file already exist. Exact text is "Press 'Delete" to delete the file and create new one instead of overwriting it".

var transferResult = session.PutFiles(localPathToUploadFile, remoteFilePath, false, transferOptions);

transferResult.Check();

The thing is that these are brand new files and so there should be no existing files to update, plus the same code was working fine until a few days ago which leads to me believe there could be something on the server which could be triggering the behavior as well.

Is the transferResult.Check() doing more than just checking?

Please help

Thanks!