Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

ALV

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.

Tags:
Former Member
Not what you were looking for? View more on this topic or Ask a question