need help on basic script

Advertisement

edlee
Joined:
Posts:
2
Location:
CA

need help on basic script

Hi all i am trying to automate download every night from a sftp site
there are 3 folders i would like to download

folder1
folder2
folder3

i created a batch file
called download.bat
winscp.exe /console /command "option batch abort" "open username:password@sftp.website.com" "get folder1\* c:\download"

it runs but nothing happens what am I doing wrong

thank you all for your help

Reply with quote

Advertisement

martin
Site Admin
martin avatar
Joined:
Posts:
27,253
Location:
Prague, Czechia

Re: need help on basic script

Is folder1 subfolder of the initial session folder?
Try using full path instead.
Also make sure you use forward slash for remote paths.
_________________
Martin Prikryl

Reply with quote

edlee
Joined:
Posts:
2
Location:
CA

Re: need help on basic script

martin wrote:

Is folder1 subfolder of the initial session folder?
Try using full path instead.
Also make sure you use forward slash for remote paths.

Hi prikryl

folder1 is a subfolder and I just tried using forward slashes as you suggested but nothing happens

what is the difference between winscp.exe and winscp.com

Reply with quote

martin
Site Admin
martin avatar
Joined:
Posts:
27,253
Location:
Prague, Czechia

Re: need help on basic script

edlee wrote:

folder1 is a subfolder and I just tried using forward slashes as you suggested but nothing happens
Please post a log file.

what is the difference between winscp.exe and winscp.com
Please read documentation:
https://winscp.net/eng/docs/executables
_________________
Martin Prikryl

Reply with quote

Advertisement

You can post new topics in this forum