You cannot do this on command-line only. If it was possible, the solution in WinSCP documentation would show it instead of the use of wrapper script.
The closest you can get with command-line only is using file mask with time constraint. For example, if you know that one file per day is added only, you can use
*>1Dmask to select files (one file actually) created within the last 24 hours.
How do i achieve this using winscp command line automation commands?
There should be NO space betweenmy command currently reads "get //ftp05155/FTP*.* <1d"
*.*and the time constraint + It should be
"C:\Program Files\WinSCP5.7\WinSCP.com" ^ /log="C:\Program Files\WinSCP5.7\WinSCP.log" /ini=nul ^ /command ^ "open ftp://electpub:email@example.com/" ^ "get *.zip /ElecMediaOUT/ -filemask>=2H H:\FTP-Blackwell\" ^ "exit"
It should probably be:Pls let me know the correct syntax to be used for "get" with "filemask" script in a batch file.
"get /ElecMediaOUT/*.zip -filemask>=2H H:\FTP-Blackwell\" ^
We need a complete log file to help you.Can help me with that.
You can post new topics in this forum