Vielen Dank für eure interresanten Lösungsansätze.
Hier jetzt meine endgültige Lösung,
die ich aus euren Vorschlägen zusammengestellt habe.
Eine Copy-Strecke die eingebunden wird.
*// standard include for all interactive programs ----------------------------
*// named hexadecimal constants for function keys ----------------------------
D ds_HexKey ds
D f01 1a inz(x'31')
D f02 1a inz(x'32')
D f03 1a inz(x'33')
...usw
D clear 1a inz(x'BD')
D enter 1a inz(x'F1')
D help 1a inz(x'F3')
D pagup 1a inz(x'F4')
D pagdn 1a inz(x'F5')
D print 1a inz(x'F6')
D home 1a inz(x'F8')
D ds_TxtKey ds
D 10a inz('F01 ')
D 10a inz('F02 ')
D 10a inz('F03 ')
... usw
d tb_HexKey_Ptr s * inz( %addr( ds_HexKey ) )
d tb_TxtKey_Ptr s * inz( %addr( ds_TxtKey ) )
D tb_HexKey s 1 dim(31) based(tb_HexKey_Ptr)
D tb_TxtKey s 10 dim(31) based(tb_TxtKey_Ptr)
und dann später im programm
if w#fkey = f06;
Text = tb_TxtKey(%lookup(w#fkey:tb_HexKey));
endif;
Dies ermöglicht mir beides sowohl die Übersetzung als auch
die direkte Ansprache von Befehlstasten.
Für das direkte füllen der tabelle in der D-Karte benötige ich
hier leider 2 Datenstrukturen.
Bookmarks