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

6packnbuzzed

SFTP upload script not moving files

Hello -
I'm having issues uploading files via SFTP to a remote host.Its supposed to move day old files to a temp folder, then upload those files to the sftp. I need it to run early morning through task scheduler but it doesn't move any files and i don't get any errors. If i run my batch file manually it works fine.. please help.

Batch:
cd C:\temp
del /q *.*
ROBOCOPY /MAXAGE:1 \\192.168.0.2\folder\folder\folder C:\temp
cd C:\Program Files (x86)\WinSCP
winscp.com /script=winscp.txt
 
exit


Script file:

option batch off
option confirm off
open sftp://user:password@URL.com
put C:\temp\*.* /tlogs/
 
exit