on 12-15-2006 12:25 PM
Someone have documentation about the icon 'traffic light' in the ALV?
thanks
Hi mpm,
1. Its simple
2. We have to use the layout of alv also.
and one extra field in the internal table.
3. Just copy paste in new program.
REPORT abc.
TYPE-POOLS : slis.
DATA : alvly TYPE slis_layout_alv.
DATA : alvfc TYPE slis_t_fieldcat_alv.
DATA : BEGIN OF itab OCCURS 0,
lt TYPE i,
matnr LIKE mara-matnr,
END OF itab.
END-OF-SELECTION.
itab-lt = 1.
APPEND itab.
itab-lt = 2.
APPEND itab.
itab-lt = 3.
APPEND itab.
itab-lt = 1.
APPEND itab.
itab-lt = 3.
APPEND itab.
itab-lt = 3.
APPEND itab.
itab-lt = 3.
APPEND itab.
*----
alvly-lights_fieldname = 'LT'.
alvly-lights_tabname = 'ITAB'.
CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'
EXPORTING
i_program_name = sy-repid
i_internal_tabname = 'ITAB'
i_inclname = sy-repid
CHANGING
ct_fieldcat = alvfc.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = sy-repid
it_fieldcat = alvfc
is_layout = alvly
i_save = 'A'
TABLES
t_outtab = itab.
regards,
amit m.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Refer Std program - <b>BCALV_GRID_04</b>
Suggest you to Search in SDN with key - <b>traffic light</b>
Will get few more useful related Posts.
Also refer the links
http://www.sapfans.com/forums/viewtopic.php?t=79424
http://www.sapfans.com/forums/viewtopic.php?t=24512
Reward points if this Helps.
Manish
Message was edited by:
Manish Kumar
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi!
Following on from Manish - you can also get some useful general info about icons (including a list of them) under the F1 help on the write statement (click on a WRITE statement in an abap and hit F1). Then click the AS ICON example link.
Traffic lights actually display as ICON_RED_LIGHT, ICON_YELLOW_LIGHT or ICON_GREEN_LIGHT - you just need to set the right one for your requirement and WRITE AS ICON (or the ALV equivalent).
Regards
Robin
User | Count |
---|---|
83 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.