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

p0630034

Hi Martin,

This jogged a memory. Figured the issue out thanks. It was the DNS.
martin

Can you even "ping" (or connect to in any way) that host name from the machine, where WinSCP does not work?
p0630034

Hi Martin,

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.
martin

Re: Max characters in HostName?

There's no limit. Definitely not less than 26 characters.
Please attach a full session log file both from GUI and the code.
p0630034

Max characters in HostName?

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.