2014 Jul 21 1:05 PM
Hi Experts,
I have a quick (probably very simple) issue on programs using ALV grid/lists.
We have a program, dointg some treatmeant.
At end of execution of program we display errors and processing messages viathe ALV grid.
So it is working fine on foreground.
But when we execute it in background we have no spool. nothing. Even in SM37 not the spool icon.
I understood that normally we could have the ALV content in the spool. But I do not understand what is wrong.
Could some experts help me to understand what is wrong and hwo to solve ??
Thanks for your help.
S.N
2014 Jul 21 2:02 PM
Hi,
Have you tried to run it via ALV_LIST* FM. I guess something related to spool and print parameters.
Remove code if have explicitly use any code to send the output to spool. could you please paste your code here to understand the problem clearly.
regards,
Deepti
2014 Jul 21 1:26 PM
Hi,
In REUSE_ALV_GRID_DISPLAY,
fill :
ls_print-print = 'X'.
ls_print-no_print_listinfos = 'X'.
Thanks,
Anil
2021 Nov 18 4:13 AM
2014 Jul 21 1:28 PM
Hi,
DATA WA TYPE SLIS_PRINT_ALV.
WA-PRINT = 'X'
Importing Parameter of alv list
IS_PRINT = WA.
Regards
Arun VS
2014 Jul 21 1:48 PM
Thanks ARUN & Anil.
I triend your options.
But it does not work.
With that ls_print use, I have the window asking for the print but when executed in the background still I haven't any spool.
My ALV list on foreground has 2 lines.
Any other help please ?
Thx
S.N
2014 Jul 21 2:14 PM
How did you create your alv grid? object oriented with set_table_for_first_display method?
Regards
Michael
2014 Jul 21 2:41 PM
Hi Newbie,
The importing parameter IS_PRINT of ALV List will solve your issue. I have tested this.
Data : wa_print type SLIS_PRINT_ALV.
wa_print-print = 'X'.
wa_print-no_print_listinfos = 'X'.
Now you have to make separate call for ALV in foreground and background .
For that,
If sy-batch = 'X'.
call function module by passing IS_PRINT parameter(wa_print).
else.
call function module without IS_PRINT.
endif.
Test the spool using sp01.
Regards
Sreekanth
2023 May 08 3:45 PM
2014 Jul 21 2:02 PM
Hi,
Have you tried to run it via ALV_LIST* FM. I guess something related to spool and print parameters.
Remove code if have explicitly use any code to send the output to spool. could you please paste your code here to understand the problem clearly.
regards,
Deepti
2014 Jul 21 2:57 PM
Hi Deepti.
my colleagues who made the code found the issue and now they 're using ALV list function.
It is working now.
The spool generated is not really friendly but at least a godd start
Thanks all for the help.
S.N
2022 Sep 07 10:38 PM
For the spool to work in the background with REUSE_ALV_LIST_DISPLAY, you must omit the IT_FIELDCAT parameter and use the I_STRUCTURE_NAME, and you create that structure in SE11 and the spool works
Spanish
Para que funcione el SPOOL en fondo con REUSE_ALV_LIST_DISPLAY, debes omitir el parámetro IT_FIELDCAT y utilizar el I_STRUCTURE_NAME, y esa estructura la creas en SE11 y funciona el SPOOL
CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
EXPORTING
I_STRUCTURE_NAME = 'ZES_LAYOUT_ZFUEL01'
TABLES
t_outtab = gt_outtab
EXCEPTIONS
PROGRAM_ERROR = 1
OTHERS = 2
.