I am trying to create a WinSCP script/command to copy a server file to a local directory once per day using a scheduled task. I have been able to get it to work if the file is in my home directory but the file is in another directory above my home directory. I'm not a programmer so I just have no idea if this is even possible and would appreciate any help.
I started with a basic command that works. When I log in to the server, it puts me in a home directory set up by the organization.
/command "open sftp://username:firstname.lastname@example.org/" "get test.txt C:\Users\Raventhrone\Desktop\"
I've then tried the following with no success:
/command "open sftp://username:email@example.com/folder1" "get test2.txt C:\Users\Raventhrone\Desktop\"
/command "open sftp://username:firstname.lastname@example.org/" "get /folder1/test2.txt C:\Users\Raventhrone\Desktop\"
I also played with some directory changing commands but can't seem to get anywhere. And I don't need to just go into a folder below my home directory, I need to go up to a completely different directory that I have access to, ie. "afs/domain.ca/software/windows/app/group/dropbox". My home directory by contrast would be "afs/domain.ca/home/e/r/username/".
Thanks for any assistance!