09-26-2008 5:49 AM
Hi experts,
i want to display pagenumber and total no of pages like 1 of 5 in ALV when Listoutput is selected please say some ideas or possible few example....
Regards,
vino.
09-26-2008 5:51 AM
Hi,
If you want to display the page number information, you have to put it in
the exporting parameter "IT_LIST_COMMENTARY" in the form "TOP-OF-PAGE"of
your program, and not in a preceding part.
For example:
FORM top_of_page.
DATA: ls_line TYPE slis_listheader.
REFRESH gt_list_top_of_page.
CLEAR ls_line.
ls_line-typ = 'S'.
ls_line-key = 'Page number:'.
ls_line-info = sy-pagno.
APPEND ls_line TO gt_list_top_of_page.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
it_list_commentary = gt_list_top_of_page.
ENDFORM.
If you want to make a test, just add "WRITE : SY-PAGNO" to the form
"TOP-OF-PAGE" of your program.
09-26-2008 5:51 AM
Hi,
If you want to display the page number information, you have to put it in
the exporting parameter "IT_LIST_COMMENTARY" in the form "TOP-OF-PAGE"of
your program, and not in a preceding part.
For example:
FORM top_of_page.
DATA: ls_line TYPE slis_listheader.
REFRESH gt_list_top_of_page.
CLEAR ls_line.
ls_line-typ = 'S'.
ls_line-key = 'Page number:'.
ls_line-info = sy-pagno.
APPEND ls_line TO gt_list_top_of_page.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
it_list_commentary = gt_list_top_of_page.
ENDFORM.
If you want to make a test, just add "WRITE : SY-PAGNO" to the form
"TOP-OF-PAGE" of your program.
09-26-2008 5:55 AM
You can give sy-pagno for the current page number in the TOP-OF-PAGE EVENT and about the total number of page just check the number of line which can be in a single page from the internal table you are passing to alv
Edited by: Midhun Abraham on Sep 26, 2008 6:55 AM