Student [3]

Student

Monday, December 7, 2015 6:51 PM - Julian Hnandez

Hi, How can i simulate an arrows(left,right,down,up) keypress ?
_____________________________________________________
http://www.vt100.net/docs/vt100-ug/table3-6.html
My Code
_____________________________________________________
Sub Main

' turn on synchronous mode
xsh.Screen.Synchronous = True


' find FTP route
xsh.Screen.WaitForString chr(62)
xsh.Screen.Send Chr(111)
xsh.Screen.WaitForString chr(62)
xsh.Screen.Send Chr(116)
scr.screen.Send Chr(27) & "OA"

' turn off synchronous mode
xsh.Screen.Synchronous = False
End Sub


-------------------------------------------
Vandyke code example
______________________-
# $language = "VBScript"
# $interface = "1.0"

' This script simulates an F3 keypress (VT100 keyboard)

Sub Main

' Simulate F3 by sending ESC-OR
'
scr.screen.Send Chr(27) & "OR"

End Sub
--------------------------------------------------------------

Program Ver. : Xshell 4


Re: Student

Tuesday, December 8, 2015 6:24 AM - Support

You can simulate them as follows:

Up => xsh.screen.Send Chr(27) & "OA"
Down => xsh.screen.Send Chr(27) & "OB"
Right => xsh.screen.Send Chr(27) & "OC"
Left => xsh.screen.Send Chr(27) & "OD"

Technical Support

Like us on Facebook
Follow us on Twitter
Visit our blog Blog


Re: Student

Monday, December 21, 2015 4:22 AM - Julian Hnandez

Hi again,I need to know other different form to simulate "arrow Keypress" cause xsh.screen.Send Chr(27) & "OA"
xsh.screen.Send Chr(27) & "OB"
xsh.screen.Send Chr(27) & "OC"
xsh.screen.Send Chr(27) & "OD"
is interpreted by the divice only like "ESC" Keypress and return to main screen
Help me :(


Re: Student

Wednesday, December 23, 2015 1:13 AM - zoo

According to the TERM type you are using, the arrow character can be different.
There is need to find out what character is each arrow key.

By using the cat command, we can do this.
After the cat command, type arrow keys one by one.

In my case, it shows like this:
-bash-4.1$ cat
^[[A^[[B^[[C^[[D

You know ^[ char is ESC.


Previous views: 185