09-21-2010 6:28 AM
Hi all,
How to create a spool request for an ALV report by using the FM "REUSE_ALV_GRID_DISPLAY". is it possible to create the spool request with this FM's parameter IS_PRINT. Please give some hint if it is possible.
Thanks in advance,
etienne.
09-21-2010 6:42 AM
hi,
it is possible...check the below code...
DATA: w_print TYPE slis_print_alv.
w_print-print = 'X'.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = g_program
i_structure_name = "structure name
is_print = w_print
TABLES
t_outtab = i_t001.
after this a spool number will be created and will be displayed as a message..
regards,
syed
09-21-2010 7:00 AM
Hi,
Please go through the beloe code
DATA: wa_print TYPE slis_print_alv.
wa_print-print = 'X'.
pass wa_print to Is_print in the exporting paramters list of Function module Reuse_alv_grid_display.
and then go to tcode SP01.. to check the spool request.. and click on spool request to see the ALV output..
hope this will help you..
Regards,
Kiran
09-21-2010 7:16 AM
Hi kiran & syed,
I already tried this. it also creates the spool request but it is showing the message "Formatting set to 'X_65_132". so wen checking the Tcode sp01 the report is not in the correct format. like - values for only one column is coming.
so any solution to overcome this.
thanks once again
09-21-2010 7:30 AM
Hi Etiene,
You could use PRI_PARAMS structure in print_ctrl of slis_print_alv to pass the page length of list, line width of list etc.
Hope it helps
Sujay