04-06-2006 8:59 AM
Hi
How can we get icons ( like grater than symbol or equal to symbol )for a field in ITAB and display an icon according to the result we get...
also please let me know where we can find the code for a particular icon...
04-06-2006 9:12 AM
Hi rahul,
1. simple
2. just copy paste this in new program.
3. <b>it will show
EQUAL to
GREATER than ICON
from field of internal table.</b>
4.
REPORT abc.
TYPE-POOLS: icon.
*----
DATA : BEGIN OF itab OCCURS 0,
bukrs LIKE t001-bukrs,
myicon(100) TYPE c,
END OF itab.
SELECT * FROM t001
INTO CORRESPONDING FIELDS OF TABLE itab.
*----
important.
LOOP AT itab.
IF sy-tabix >= 5.
<b> MOVE '@1G@' TO itab-myicon.</b>
ELSE.
<b>MOVE '@1I@' TO itab-myicon</b>.
ENDIF.
MODIFY itab.
ENDLOOP.
LOOP AT itab.
WRITE 😕 itab-bukrs , itab-myicon.
ENDLOOP.
5. double icon in TYPE-POOLS: icon
and u will get all list of icons.
regards,
amit m.
04-06-2006 9:04 AM
04-06-2006 9:04 AM
Hello,
You can get help of Icon, in ABAP Help itself. Click on ICon list, you will get the list of ICons with its code.
Regards,
Naimesh
04-06-2006 9:05 AM
Hi,
check the program <b>BALVSD01</b>, which uses trafic lights.
Regards
vijay
04-06-2006 9:08 AM
To see all icons, use transaction ICON.
To have an icon in an ALV list, specify type-pools: icon in your program, assign the icon name to your field (wa_out-stat = ICON_RED_LIGHT) and in your fieldcatalog specify wa_fcat-icon = X for that column.
04-06-2006 9:12 AM
Hi rahul,
1. simple
2. just copy paste this in new program.
3. <b>it will show
EQUAL to
GREATER than ICON
from field of internal table.</b>
4.
REPORT abc.
TYPE-POOLS: icon.
*----
DATA : BEGIN OF itab OCCURS 0,
bukrs LIKE t001-bukrs,
myicon(100) TYPE c,
END OF itab.
SELECT * FROM t001
INTO CORRESPONDING FIELDS OF TABLE itab.
*----
important.
LOOP AT itab.
IF sy-tabix >= 5.
<b> MOVE '@1G@' TO itab-myicon.</b>
ELSE.
<b>MOVE '@1I@' TO itab-myicon</b>.
ENDIF.
MODIFY itab.
ENDLOOP.
LOOP AT itab.
WRITE 😕 itab-bukrs , itab-myicon.
ENDLOOP.
5. double icon in TYPE-POOLS: icon
and u will get all list of icons.
regards,
amit m.
04-06-2006 9:13 AM
You can display available icons via report SHOWICON. In your program you have to add TYPE-POOLS: icon (or include), so they will be available in a nice readable format like ICON_SOMETHING.
Peter