Topic "Works in GUI, does not work in code."

Author Message
Noob

Guest


I need some help figuring out what I'm doing wrong. I can connect to a site through the gui using:
Protocol: sftp
hostname: sftp.getclever.com
port number: 22
user name: righteous-pass-8586
password: insert password here
private key file: blank

How can I recreate those settings in code?
GTypeR

Guest


Noob wrote:
I need some help figuring out what I'm doing wrong. I can connect to a site through the gui using:
Protocol: sftp
hostname: sftp.getclever.com
port number: 22
user name: righteous-pass-8586
password: insert password here
private key file: blank

How can I recreate those settings in code?


https://winscp.net/eng/docs/scripting

https://winscp.net/eng/docs/scriptcommand_open

It will be something like:

Code:
winscp.exe /console /command "option batch abort" "open sftp://righteous-pass-8586:insertpasswordhere@getclever.com"


or

Code:
winscp.exe /console /script=example.txt


and in example.txt have something like:

Code:
# Automatically abort script on errors
option batch abort
# Disable overwrite confirmations that conflict with the previous
option confirm off
# Connect using a password
open sftp://righteous-pass-8586:insertpasswordhere@getclever.com


Then insert your code to do something like "cd" to change directory or "lcd" to change local directory and "put" and "get"
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