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

ALV: Refreshing Header Info

0 Likes
611

Hello Guru's,

i've got a Report which lists some Employes. The Data is displayed in an ALV. The Header of this ALV displays the Count of Employes displayed.

My Problem: Is there any posibility to refresh the Employee Count in the Header when maybe a Filter on the ALV is set and the displayed Count of Employes changed?

Regards

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
542

Try implementing the AFTER_USER_COMMAND event of CL_GUI_ALV_GRID class.

In its implementation checked if the filter was selected, determine the number of the rows filtered.

There is method get_filtered_entries in class cl_gui_alv_grid which returns a table of all entries hidden by the filter. This will help you in determining the number of records hidden by the filter and so you can calculate the number of records shown as a result of filter.

Hope this helps.

Reward points if helpful.

Thanks,

Balaji

Edited by: Balaji Ganapathiraman on Feb 20, 2008 12:57 PM

2 REPLIES 2
Read only

Former Member
0 Likes
543

Try implementing the AFTER_USER_COMMAND event of CL_GUI_ALV_GRID class.

In its implementation checked if the filter was selected, determine the number of the rows filtered.

There is method get_filtered_entries in class cl_gui_alv_grid which returns a table of all entries hidden by the filter. This will help you in determining the number of records hidden by the filter and so you can calculate the number of records shown as a result of filter.

Hope this helps.

Reward points if helpful.

Thanks,

Balaji

Edited by: Balaji Ganapathiraman on Feb 20, 2008 12:57 PM

Read only

0 Likes
542

Hy Balaji,

your tip workes successfully. Thanks for this! Now i got another question: The method returns a hash table. Is there some posibility to compare the values of the hashtable with the values in my internal table?

Commands like loop are not allowed on hashed tables.

Regards