ABAP/4 Example Code: HIDE and AT LINE-SELECTION
Example
DATA: it_spfli TYPE TABLE OF spfli WITH HEADER LINE,
it_sflight TYPE TABLE OF sflight WITH HEADER LINE.
START-OF-SELECTION.
SELECT * FROM spfli
INTO TABLE it_spfli.
IF SY-SUBRC = 0.
LOOP AT it_spfli.
WRITE:/ it_spfli-CARRID, it_spfli-CONNID,
it_spfli-CITYFROM, it_spfli-AIRPFROM,
it_spfli-CITYTO, it_spfli-AIRPTO.
HIDE: it_spfli-CARRID, it_spfli-CONNID.
ENDLOOP.
ENDIF.
AT LINE-SELECTION.
SELECT * FROM sflight
INTO TABLE it_sflight
WHERE carrid = it_spfli-carrid
AND connid = it_spfli-connid.
IF SY-SUBRC = 0.
FORMAT COLOR = 3.
WRITE:/ it_spfli-CARRID, it_spfli-CONNID.
FORMAT COLOR OFF.
LOOP AT it_sflight.
WRITE:/ it_sflight-FLDATE, it_sflight-PRICE.
ENDLOOP.
ENDIF.
The output is:
When line selected by double click
- thitima's blog
- 10636 reads
this code is gud example
Post new comment