Missing data from .Execute return - WeOnlyDo Discussion board

Missing data from .Execute return (wodSSH / wodSSH.NET)

by Marvin, Saturday, November 13, 2021, 20:35 (894 days ago)

If i use (in VBScript):
Set connSSH = CreateObject("WeOnlyDo.wodSSHCom")
connSSH.Hostname = IP
connSSH.Protocol = 4 'ssh
connSSH.TerminalType = "TTY"
connSSH.Blocking = True
connSSH.TimeOut = 240
connSSH.StripNull = True
connSSH.AllocatePty = False
connSSH.Login = "user"
connSSH.Password = "password"
connSSH.Prompt = "regex:user@[A-Z]+\d+\s+[Cc]\:\\.+\>"
connSSH.LicenseKey = "xxxx.xxxx.xxxx.xxxx"
connSSH.Connect
connSSH.WaitFor "regex:user@[A-Z]+\d+\s+[Cc]\:\\.+\>"
bufferSSH = connSSH.Execute("dir /s C:\folder\" & file.csv" & VbCrLf, "regex:user@[A-Z]+\d+\s+[Cc]\:\\.+\>$")

bufferSSH shows:
Volume in drive C has no label.
Volume Serial Number is 881A-0E79

But if i SSH into it manually i see:
user@MACHINE01 C:\folder>dir /s C:\
Volume in drive C has no label.
Volume Serial Number is 881A-0E79
File Not Found

user@MACHINE01 C:\folder>

Why is that? How do i pick up the "File Not Found"? I have no trouble picking up data from other commands. If the file existed and on other commands i would pick up the rest of the return with no issue.


Complete thread: