SendKeys Method

Top  Previous  Next

The SendKeys method can be used to send key sequences to the mainframe (including AID keys). By using special codes you can send several kinds of keys. These codes consist of an Escape character ("@") and a mnemonic code that corresponds to the supported host functions.

 

Visual Basic Syntax

 

TNBXSync.SendKeys (Keys As String)

 

Delphi Syntax

 

TNBXSync.SendKeys (Keys:string);

 

 

Remarks

 

The following table lists the functions keys and its corresponding codes.

 

Code Value

Meaning

@A@Q

Attention

@<

Backspace

@B

BackTab (Left Tab)

@C

Clear

@E

Enter

@F

Erase Field

@A@Q

Sys Request

@T

Tab (Right Tab)

@x

PA1

@y

PA2

@z

PA3

@1

PF1

@2

PF2

@3

PF3

@4

PF4

@5

PF5

@6

PF6

@7

PF7

@8

PF8

@9

PF9

@a

PF10

@b

PF11

@c

PF12

@d

PF13

@e

PF14

@f

PF15

@g

PF16

@h

PF17

@i

PF18

 

This method complements the SendKeys method from TNB3270X controls and TNB5250X, adding the possibility to send several key sequences separated by aid keys and waits (@W). This is the main difference between both SendKeys methods. This mean that you can navigate through several screens with a single method call.

 

See also TelnetControl property of TNBXSync control and SendKeys method from TNB3270X/TNB5250X controls.