Topic "Running a .bat script via WinSCPNet.dll"

Author Message
[View user's profile]

Joined: 2011-11-16
Posts: 9
Location: Work
Hello, we are no longer getting the time out error, thanks for the help. Our latest issue is not being able to run a string of script commands. We were executing .bat scripts in the past to run commands on the UNIX server using the old method of A sample of how we used to do it is below. Is there some way we can run a string of commands using the new WinSCPNet.dll?

Dim SftpProcess As Process = New Process()
With SftpProcess.StartInfo
.FileName = ""
.UseShellExecute = False
.RedirectStandardInput = True
.CreateNoWindow = True
End With

With SftpProcess.StandardInput
.WriteLine("call /alps/system/upd_add.ksh")
End With
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 26890
Location: Prague, Czechia
I assume you mean "shell script", not ".bat script", right?

If you are looking for a call replacement, use Session.ExecuteCommand:

The replacements are documented in "Converting to .NET Assembly" sections:

You can post new topics in this forum


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!


About donations

$9   $19   $49   $99

About donations


WinSCP Privacy Policy

WinSCP License