ja, das geht über die INFDS:

DSPF:

A DSPSIZ(24 80 *DS3)
A PRINT
A INDARA


Programm:

fvtc050d cf e WORKSTN infds(dspfds)
f indds(bezugsz)



d dspfds ds
d Ftaste 369 369






Werte für Ftaste:

d F01 c const(X'31')
d F02 c const(X'32')
d Ende c const(X'33')
d F04 c const(X'34')
d F05 c const(X'35')
d F06 c const(X'36')
d F07 c const(X'37')
d F08 c const(X'38')
d F09 c const(X'39')
d F10 c const(X'3A')
d F11 c const(X'3B')
d F12 c const(X'3C')
d F13 c const(X'B1')
d F14 c const(X'B2')
d F15 c const(X'B3')
d F16 c const(X'B4')
d F17 c const(X'B5')

d F18 c const(X'B6')
d F19 c const(X'B7')
d F20 c const(X'B8')
d F21 c const(X'B9')
d F22 c const(X'BA')
d F23 c const(X'BB')
d F24 c const(X'BC')
d clear c const(X'BD')
d Enter c const(X'F1')
d help c const(X'F3')
d pagedown c const(X'F4')
d pageup c const(X'F5')
d print c const(X'F6')


Abfrage im Programm:

select;
when ftaste = Ende;
vxst0 = 9;
when ftaste = F12;
vxst0 = 9;
when ftaste = F13;
exsr Hilfe;
vxst0 = 1;
when ftaste = pageup;
exsr s02;
other;

endsl;


Mit den entsprechenden Hex-Codes lassen sich auf diese Weise alle gedrückten Tasten abfragen.