Skip to Content

How to execute a report in background and spool based on radio button on selection screen?

Hello All,

I have a selection screen that contains two radio buttons 1. Background 2. Spool . whenever user selects a particular radio button the report has to be executed in corresponding mode. How do I acheived this ? fbl1npng.png

fbl1npng.png (19.8 kB)
Add a comment
10|10000 characters needed characters exceeded

  • Hi Nandini,

    If report has to be run in that way then you schedule it using SM36 Trxn using BASIS person as job on certain interval, it will run in B/g and display the data into Spool.

    There is no need to have these options into Sel. Screen as these are inherent feature of any report.

    If it is ALV Report, system automatically generates the Spool using ALV_LIST in B/g.

    Regards
    Samir

Assigned Tags

Related questions

2 Answers

  • Posted on Jul 17 at 11:22 AM

    With a minimum of code, try something like the following example.

    TABLES: sscrfields.

    PARAMETERS: init RADIOBUTTON GROUP mode DEFAULT 'X' USER-COMMAND mode,
    prin RADIOBUTTON GROUP mode,
    sjob RADIOBUTTON GROUP mode.

    AT SELECTION-SCREEN.

    IF sscrfields-ucomm = 'MODE'.
    IF prin IS NOT INITIAL. sscrfields-ucomm = 'PRIN'.
    ELSEIF sjob IS NOT INITIAL..
    sscrfields-ucomm = 'SJOB'.
    ENDIF.
    ENDIF.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Jul 17 at 10:38 AM

    Hello Nandini Borse

    Spool is generated whenever report executed in background has written some output to the list (with WRITE statements).

    I don't know what the report does, but it might be that the SPOOL option is there to make the report output the results using the WRITE statement, when the BACKGROUND option could output results to a file on application server or just sent them in an email.

    Kind regards,
    Mateusz

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.