This jogged a memory. Figured the issue out thanks. It was the DNS.
Can you even "ping" (or connect to in any way) that host name from the machine, where WinSCP does not work?
Did more testing. On the machine that couldn't connect, it failed in the WinSCP program along with the script. They still both went through with the shorter hostname.
The longer hostname however does work in GUI on another machine.
There's no limit. Definitely not less than 26 characters.
Please attach a full session log file both from GUI and the code.
Hi, scripting in .net and wondering what the maximum length of the SessionOptions.HostName field is.
I have a FTP site with 2 host names bound to it. I have tested both in the WINSCP program and they both connect fine. When scripting, I get an error when trying to connect to it via the longer host name with a character count of 26. The shorter host name with a character count of 24 works.