Topic "Having Problems with GET from command line"

Author Message
cdun2

Guest


I'm trying to understand how to GET and PUT files from an SFTP site with WinSCP using without using the GUI, and I'm not having much luck.

From the GUI, in order to log in to our SFTP site, I do this:

Host name: sftp.sftpserver.net
Port Number: 21
User name: internaluser
Password: internalPassword
File protocol: SFTP
Allow SCP fallback: (true)

from there, the files I need reside at /statefiles/import

I've tried this from the command prompt:

C:\ cd c:\Program Files
C:\Program Files>WinSCP\WinSCP.com /command "get newfile.csv /statefiles/import/" "exit"

What I get back is 'No Session'

How do I do this correctly?

Thanks.
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
You need to use "open" command before "get".
See example.
_________________
Martin Prikryl
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License