Topic "Batch script 'host not found'"

Author Message
Joe_1234

Guest


I'm having a problem - I'm trying to connect to my server in a batch script, using the line:

Code:
call "C:\Program Files (x86)\WinSCP\WinSCP.com" open sftp://username:password@myserver.com


but I keep getting 'Host not found' returned in the console. However, once the terminal goes to winscp> I am able to copy and paste directly
Code:
open sftp://username:password@myserver.com
and it connects successfully. Why is this only failing when calling from a batch script? Or am I doing something wrong?

Any help is appreciated.
Joe_1234

Guest


Oh, I think I posted this in the wrong forum. Apologies. I'll post it again there.
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24512
Location: Prague, Czechia
Follow here.
_________________
Martin Prikryl
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License