Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

sort in alv grid function modules

Former Member
0 Likes
598

hi,

i want sort the data display in alv grid control using function modules......&&& make one cell with color.

please reply me .

thank u

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
563

Reward points..

3 REPLIES 3
Read only

Former Member
0 Likes
564

Reward points..

Read only

Former Member
0 Likes
563

Reward points..

Read only

Former Member
0 Likes
563

Since an individuall cell can be addressed with 2 parameters, we will need a table type structure to be included into the structure of the list data table.

The Structure that should be included must be of type "LVC_T_SCOL". If u want to color the entire row, this inner table should contain only one row with field "fname" is set to space, some color value at field "col" , "0" or "1" at fields "int" (intensified) and "inv" (inverse)

If u want to Color INDIVIDUAL cells, then for each cell column, append a line to this inner table which also contains the column name at field "fname".

-


  • Internal table for holding data

DATA BEGIN OF gt_list OCCURS 0.

INCLUDE STRUCTURE SFLIGHT.

DATA rowcolor(4) YPE C.

DATA cellcolors TYPE lvc_t_scol.

DATA END OF gt_list.

DATA ls_cellcolor TYPE lvc_s_scol.

.....

READ TABLE gt_list INDEX 5.

ls_cellcolor-fname = 'SEATSOCC'.

ls_cellcolor-color-col = '7'.

ls_cellcolor-color-int = '1'.

Append ls_cellcolor to gt_list-cellcolors.

Modify gt_list INDEX 5.

REWARD pts, if useful.

Regards

- Rishika Bawa