Post a reply

Before posting, please read how to report bug or request support effectively.

Bug reports without an attached log file are usually useless.

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

Sorry, my answer was wrong. I've corrected it.
petant

I have tried the recommended approach but it's not working. I don't get an error. It just seems to stop.

Here is the script that I am running:

option batch abort
option confirm off
open "ftp://bla-bla-bla" -explicitssl -certificate="xyz"
lcd N:\Data
put 57-1-104352.txt >1K
put 57-1-104354.txt >1K
put 57-5-105442.txt >1K
put 57-8-106914.txt >1K
put 57-169-143038.txt >1K
close
exit
martin

Re: How to not ftp a file if the file size is <1K

Use put * -filemask=*>1K /target/path/ to upload all files larger than 1 KB.

See https://winscp.net/eng/docs/file_mask#size_time

If I don't want to PUT a file if it is less than 0K do I use <0K?

That does not make sense. A file cannot have a negative size (less than 0).
petant

How to not ftp a file if the file size is <1K

I am using verison 5.1.7.

The goal is to not PUT a file on an FTP server if the file is a size 0 text file which has no data.

I have found your documentation online where you state I can use the following:

"size[KMG] Matches files smaller than size. <1K "

I am not sure exactly where to put this matching code. Do I use the <1K on the PUT command?

If I don't want to PUT a file if it is less than 0K do I use <0K?