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

eranm

Thanks.
martin

eranm wrote:

I know the * means 0 or more occurrences, would [0-9]+ work in this case?

I already wrote above that * does not do what you think.
WinSCP file mask is not a regular expression.
See https://winscp.net/eng/docs/file_mask
So + won't work either.
eranm

Hi,

Thanks for the solution.

I know the * means 0 or more occurrences, would [0-9]+ work in this case?
martin

Re: Mask Specific number of characters

There's no syntax for that. You have to repeat the set pattern:
Test_[0-9][0-9][0-9][0-9][0-9]

(Btw, Test_[0-9]* does not do what you probably think).
eranm

Mask Specific number of characters

Hi,

I'm trying to apply a mask to files, and i know the exact amount of numbers i have in file name.
what is the syntax to accomplish this?
ex:
filename: "Test_12345"
mask: Test_[0-9]{5} - not working
mask: Test_[0-9]* - working