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

martin

Re: more than one filemask error

The semicolon should not be there.
It should be:
transferOptions8.FileMask = "*>=1D|*/";


While technically the semicolon should be ignored, it's not as there's a bug:
https://winscp.net/tracker/1745
Nardog

more than one filemask error

I am trying to put files in a remote directory non-recursively as well as be less than a day old.

Filemask:
transferOptions8.FileMask = "*>=1D;|*/";


Full Code Block:
session8.Open(sessionOptions8);

                    TransferOptions transferOptions8 = new TransferOptions();
                    transferOptions8.TransferMode = TransferMode.Binary;
                    transferOptions8.FileMask = "*>=1D;|*/";
                    TransferOperationResult transferResult8;
                    transferResult8 =
                        session8.PutFiles(@"C:\Transmissions\Inbound\*", @"/from/ss/", false, transferOptions8);
                    transferResult8.Check();


The `Inbound` folder has folders in it I do not want want to send.
The error I get when running this is:

C:\>.\Sync.exe
Error: WinSCP.SessionRemoteException: Mask is invalid near '=1D;|*'.
at WinSCP.OperationResultBase.Check()

Any thoughts?