I am trying to connect to a FTP server with following setting

This setting works well and I can connect to FTP server via GUI (version 5.7.5)
However, when I try to convert these settings to script
winscp.com /command "option batch abort" "option confirm off" "open ftp://username:[email protected]:21 -   
explicittls /" "put -filemask=>1D  D:\Backups\*.bak /" "exit"
and run it from cmd, there is an error message indicated that there is 
Too many parameters for command 'open'."
What did I do wrong here and how to resolve it ?
It's
winscp.com /command "open ftp://username:[email protected]/ -explicit" ...
or simply
winscp.com /command "open ftpes://username:[email protected]/" 
See:
You get the "Too many parameters for command 'open'" because of the / after the explicittls. Or because of the explicittls itself, if you really have the spaces there in-between the - and the explicittls.
You can use Generate Transfer Code Dialog to have WinSCP generate the script or batch file for you.

Side notes:
option batch abort and option confirm off are not necessary since 5.7 anymore (they are implicit with /command);21, it's the default port for FTP;If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With