04-20-2006 12:23 PM
Hi Group,
I am using REUSE_ALV_GRID_DISPLAY and REUSE_ALV_COMMENTARY_WRITE FM to create the ABAP output
report templet.
I am getting the templet like
Report Logo
User name
report des
runtime
But I need to print like
LOGO REPORT user id runtime
on the same line,here I am attaching the code which I am using.
And also I nee to add footer with page number for this,Please suggest.
call function 'REUSE_ALV_GRID_DISPLAY'
exporting
i_callback_program = gd_repid
i_callback_top_of_page = 'TOP-OPAGE'
is_layout = gd_layout
it_fieldcat = fieldcatalog[]
i_save = 'X'
tables
t_outtab = it_ekko
exceptions
program_error = 1
others = 2.
Form top-of-page.
*ALV Header declarations
data: t_header type slis_t_listheader,
wa_header type slis_listheader,
t_line like wa_header-info,
ld_lines type i,
ld_linesc(10) type c.
Title
wa_header-typ = 'H'.
wa_header-info = ' Report'.
append wa_header to t_header.
clear wa_header.
*USER ID
wa_header-typ = 'S'.
wa_header-key = 'User ID '.
wa_header-info = sy-uname.
append wa_header to t_header.
clear wa_header.
:
:
:
Date
wa_header-typ = 'S'.
wa_header-key = 'Date: '.
CONCATENATE sy-datum+6(2) '.'
sy-datum+4(2) '.'
sy-datum(4) INTO wa_header-info. "todays date
append wa_header to t_header.
clear: wa_header.
*
call function 'REUSE_ALV_COMMENTARY_WRITE'
exporting
it_list_commentary = t_header.
i_logo = 'Z_LOGO'.
endform.
04-20-2006 12:27 PM
Hi,
Which ever one, you want in the same line, concatenate them and append to the table, rather than appending into multiple lines.
Regards,
Ravi
04-20-2006 12:27 PM
04-20-2006 12:43 PM
how to show the LOGO in almost top left of the report and also please suggest how to add footer
04-28-2006 7:45 AM
Hi,
To write a header or footer , we use the function REUSE_ALV_COMMENTARY_WRITE. This function can be used to write headers or footers for reports. To this function we pass a table of the text that we want to be written in the report. It is of type slis_t_listheader. This is a table of rows, which can of three types, HEADER, STATUS or ACTION as defined in the type slis_listheader, which is a line item of slis_t_listheader
Use the event END_OF_PAGE for footer as you hav used top_of_page for header.
Please reward for the same.