Frequently Asked Questions

How to send non-ASCII data to server?

You can try to send non-ASCII data to server as Byte array.

Here is example which will send "ls -al" command as Byte array to server using wodSSH Send Method:
Option Explicit
Dim WithEvents ssh1 As wodSSHCom 

Private Sub Form_Load()
Set ssh1 = New wodSSHCom

    ssh1.HostName = "your_hostname"
    ssh1.Login = "your_login"
    ssh1.Password = "your_password"
    ssh1.Prompt = ("regex:[\$%#>] $")
    ssh1.Connect

End Sub

Private Sub ssh1_Connected(ByVal ErrorCode As Integer, ByVal ErrorText As String)
Dim b() As Byte
    
    ReDim b(6)
    b(0) = Asc("l") 
    b(1) = Asc("s")
    b(2) = Asc(" ")
    b(3) = Asc("-")
    b(4) = Asc("a")
    b(5) = Asc("l")
    b(6) = 10
    
    ssh1.Send b
End Sub

Private Sub ssh1_PromptReceived()
    Debug.Print ssh1.Receive
End Sub


 Last updated Thu, Nov 7 2013 11:00pm

Please Wait!

Please wait... it will take a second!