Re: WinSCP .NET does not support passing literal file names without mask interpretation
Note that I have responded yout Stack Overflow post. So there's unfortunately nothing more I can suggest here.
Before posting, please read how to report bug or request support effectively.
Bug reports without an attached log file are usually useless.
[Hospital1]_0001.txt) without WinSCP listing the entire directory?
session.GetFileToDirectory("/IDEData/[Hospital1]_0001.txt", @"C:\IdeData\", true, null);
[ and ] as wildcard characters, so instead of copying the file directly, it attempts to resolve the pattern and ends up listing the entire directory. The problem is that this folder contains over one million files, so the directory listing takes around 40 minutes and triggers a timeout exception—even though I only need to copy a single file.
Test.txt, but all required files in my case include square brackets. I also tried RemotePath.EscapeFileMask(fileName), but it didn't solve my issue.
session.GetFiles(session.EscapeFileMask("/var/pathTo/[Hospital1]_001.txt"), @"C:\somewhere\*").Check(); but it didn't work either.