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

martin

Re: To automate tasks using WinSCP with BATCH file.

That means you are trying to run WinSCP command[s] directly on Windows console (or in a batch file), instead of putting them to WinSCP script and running WinSCP from console/batch file.

You might be having this or similar problem:
https://winscp.net/eng/docs/faq_batch_file#cmd
TITI31

To automate tasks using WinSCP with BATCH file.

Hi,

For example, here is a command to open a session:
open ftp://fiveref:XXXYYYYZZZZ@ftp3.culturevelo.com/ -hostkey="ftp3.culturevelo.com"

First error:
"open" n'est pas reconnu en tant commande interne ou externe.

I think that is not a geed declaration.
TITI31

To automate tasks using WinSCP with BATCH file.

Hi everyone,

I am a new user on WinSCP. I don't know how automate WinSCP tasks in order to retrieve a file in FTP. It seems there are three steps:

  1. To log in;
  2. To retrieve a file in FTP.
  3. To log out.

Of course, there are several pages where it explains different WinSCP commands. I built different scripts, it doesn't work.
https://winscp.net/eng/docs/scripting#commands
https://winscp.net/eng/docs/scriptcommand_get#examples
Batch files often tell me get command or another doesn't exist.

For information, I am under Windows11.

Thank you for your help.