01-08-2009 12:34 PM
Hi all,
I have developed module pool with table control, the requirement is to highlight some columns with background color.
I tried to use SCREEN-COLOR field but it is not usedful. Please let me know how to achieve this requirements..
Pts are assured.
regards,
mahantesh
01-09-2009 8:52 AM
Hi Mahesh,
Yes , you are true.
You cannot color the columns in the table control.So Instead of table control you can create a ALV grid with ALV Function modules or with ALv oops.
So try with the Grid.
Regards,
Madhavi
01-08-2009 12:43 PM
01-09-2009 4:11 AM
Hi,
Use it this way:-
If you want the some fields for a records to be highlighted, then use the code in PBO.
Or if you want that if user performs any action and then the fields should be highlighted, then use the code in PAI under user command.
Take the group1 for all the fields as 'ABC' which needs to be highlighted.
if <condition>. "if you want to highlight on some condition
if ( screen-group1 = 'ABC' ). "fields with group1 ABC to be highlighted
loop at screen.
screen-intensified = 'X'. "apply color
endloop.
modify screen. "modify screen
endif.
endif.
Similarly you can remove this color using:-
if <condition>. "if you want to un-highlight on some condition
if ( screen-group1 = 'ABC' ). "fields with group1 ABC to be un-highlighted
loop at screen.
screen-intensified = ' '. "remove color
endloop.
modify screen. "modify screen
endif.
endif.
Hope this solves your problem.
Thanks & Regards,
Tarun Gambhir
01-09-2009 5:45 AM
Hi Tarun,
This intensified field is used to highlight the text in the particular column, but I want to highlight the entire column even if some of it's cell are blank.
Can it be done?
regards,
mahantesh
05-18-2015 3:08 PM
01-09-2009 8:08 AM
01-09-2009 8:52 AM
Hi Mahesh,
Yes , you are true.
You cannot color the columns in the table control.So Instead of table control you can create a ALV grid with ALV Function modules or with ALv oops.
So try with the Grid.
Regards,
Madhavi