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

jb@mtrade.com

Re: SessionRemoteException and remote directories

martin wrote:

So why don't the admins set the home folder to some existing directory?


Thanks for the reply. The explanation made no sense. They cited no issues with the CoreFTP client with a missing home directory and reasoned that it was something I need to change.

Fortunately, after whining, the remote admins have responded to my appeal and created a "home" directory.
martin

Re: SessionRemoteException and remote directories

So why don't the admins set the home folder to some existing directory?
jb@mtrade.com

SessionRemoteException and remote directories

I am attempting to automate connectivity to a remote SFTP Server using WinSCP within Powershell. The SFTP Server admins do not want to create a local directory. So, I get a SessionRemoteException with the error below when I attempt a $session.Open. I attempted to catch the exception so I could proceed to a full-path directory provided by the SFTP Server admins, but the $session object is null.

Cannot get real path for '.'.
No such file or directory.
Error code: 2
Error message from server (en): No such file

Is there a way to ignore this exception or specify an alternative remote directory?