04-03-2008 5:48 AM
hi experts,
i want to display a alv report and normal report in the same screen one below the other .is it possible,if so please guide me how to do that.
04-03-2008 6:16 AM
HI Praveen,
It is not possible to print normal and alv list in the same list .
if u want to display to or more lists is in the same list display
u can use REUSE_BLOCK_LIST_DISPLAY.......
U can append any no of lists in the same list display using..
the sequence of function modules...
'REUSE_ALV_BLOCK_LIST_INIT' ( To initiate the blocked list)
'REUSE_ALV_BLOCK_LIST_APPEND' (Use this as many times as u want the number of lists to display)
'REUSE_ALV_BLOCK_LIST_DISPLAY' ( To display the blocked list).
Reward if helpful
Jagadish
04-03-2008 5:52 AM
i have an idea of blocked alv in which we can display 2 or more alv....but my req is one alv and other is normal...help me out
04-03-2008 5:53 AM
In that case U have to use REUSE_ALV_LIST_DISPLAY. and also u have to take one variable for line count. now if the lincount variable will be same as ur dbcount value then after that u can use to display ur second report.
If satisfied give points.................
04-03-2008 6:12 AM
04-03-2008 6:16 AM
HI Praveen,
It is not possible to print normal and alv list in the same list .
if u want to display to or more lists is in the same list display
u can use REUSE_BLOCK_LIST_DISPLAY.......
U can append any no of lists in the same list display using..
the sequence of function modules...
'REUSE_ALV_BLOCK_LIST_INIT' ( To initiate the blocked list)
'REUSE_ALV_BLOCK_LIST_APPEND' (Use this as many times as u want the number of lists to display)
'REUSE_ALV_BLOCK_LIST_DISPLAY' ( To display the blocked list).
Reward if helpful
Jagadish
04-03-2008 7:05 AM
Hi Praveen,
It is not possible to display noraml and alv,you can display two alv together.......
by FM
'REUSE_ALV_BLOCK_LIST_DISPLAY'
04-03-2008 7:16 AM
Praveen Kumar,
You can create Normal and ALV together.
Proceed the following way .
1. Create ALV out using REUSE_ALV_LIST_DISPLAY.
2.Build events table with END_OF_LIST event.
declare events table like this.
Build events table .
data :
i_events type slis_t_event,
w_events like line of i_events.
3.
pass this events table through REUSE_ALV_LIST_DISPLAY.
w_events-name = 'END_OF_LIST' .
w_events-form = 'END_OF_LIST' .
append w_events to i_events.
clear w_events.
4.
Use just WRITE statement to output your Normal report. It works.
data :l_program type sy-repid.
l_program = sy-repid.
call function 'REUSE_ALV_GRID_DISPLAY'
exporting
i_callback_program = l_program
it_events = i_events
it_fieldcat = i_fieldcat
tables
t_outtab = i_pa0001.
if sy-subrc <> 0.
message id sy-msgid type sy-msgty number sy-msgno
with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
endif.
I hope that it solves your problem.
Regards,
Venkat.O
form end_of_list.
data: inc_colnum type i.
uline .
inc_colnum = sy-linsz - 60.
write: / 'Report: ', sy-repid(18).
write at 30(inc_colnum) sy-title centered.
inc_colnum = sy-linsz - 20.
write: at inc_colnum 'Page: ', (11) sy-pagno right-justified.
write: / 'Client: ', sy-mandt.
inc_colnum = sy-linsz - 20.
write: at inc_colnum 'Date: ', sy-datum.
write: / 'User : ', sy-uname.
inc_colnum = sy-linsz - 60.
case clicked .
when 'ALV1'.
write at 30(inc_colnum) 'Normal ALV' centered.
when 'ALV2'.
write at 30(inc_colnum) 'Blocked ALV' centered.
when 'ALV3'.
write at 30(inc_colnum) 'Hierarchical ALV' centered.
when 'ALV4'.
write at 30(inc_colnum) 'Blocked Hier. ALV' centered.
endcase.
inc_colnum = sy-linsz - 20.
write: at inc_colnum 'Time: ', (10) sy-uzeit right-justified.
uline .
endform.
04-03-2008 7:21 AM
Praveen Kumar, If you want to display normal report first and second ALV use TOP_OF_PAGE event . Regards, Venkat.O