Click here to Skip to main content
16,004,882 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi
In my project we are using wiscpUtility class to connect sftp server for file transfers, winscp utility using
SessionOptions
class which has the method called
oSession.DuplicateFile(sourcepath,destinationpath)
method which works for one sftp server and not working for another sftp server giving error as "operation not supported", can any one help me in that, I have been struggling for long.

Thanks

What I have tried:

I am not sure how to get it. how could I check which sftp server supports duplicatefile() method and which doesn't support
Posted
Updated 31-May-18 1:49am

1 solution

Looks like this WinSCP function uses internally an SFTP command that is not supported by all servers. I guess it is the copy-file command which is not a standard command and therefore only partial supported.

The solution is to open another SFTP session, navigating to the target directory, and uploading the file again to that location.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900