Print spool requests by background job

Hi,
we want to print spool requests by a background job. Do you know any abap program to do this.? I search at the programs RSPO... , but i can't find anyone to do this.
Can anybody help me.
Regards Oliver

Hi,
i found a report for this issue. You can use the report RSPO0015

Similar Messages

  • Setting format for spool requests in background jobs, for emails

    Hi,
    Don't know if this is the correct forum, but I'll give it a go (will appricate info regarding what forum is applicable otherwise.)
    For some periodical background jobs that we run in ECC, we have in the job set up that a mail group of people to receives the spool request via mail. Vi have used this a few years now. When we recently uppgraded from R/3 to ECC, the format of the spool request sent as mail attachment changed from .txt to .htm. This is however not the problem for us.
    We now have a scenario with a daily mail report, i.e. delivered as an attachment (htm-format) in our email system (Lotus Notes).
    So far so good, and nothing really new about this, except the changed format.
    What the users want is to print this report. It can be done, but it is a wide report, so it cuts the report in three pieces, as there is no automatic sizing to landscape printout and/our automatic sizing to one page. The best solution would be if it automatically was set up to landscape + automatically fit page size. Which format (.txt .htm .xls .pdf...) we receive the file in, is not really important, as long as we can print it directly without having to reformat it. Now we have to save the file to excel manually after we receive it, and then format the excel sheet. Just for printout purpose, so it is annoying work.
    Any solution available? (preferrably without coding)
    BR,
    Niclas

    Hi NTR,
    If you are using FM REUSE_ALV_LIST_DISPLAY to print your ALV Report it has got a paramter IS_PRINT in which you can pass your format type. Below is the field name where you have to pass your format type.
    IS_PRINT-print_ctrl-PRI_PARAMS-PAART
    Regards
    Bala

  • Alv show in report but when see in spool (after run background job) there i

    my program have some error when i run result alv show in report but when see in spool (after run background job) there is no data, (other program can see result in spool)
    Please help
    here is some example of my program
    ********************************declare internal table*****************************
    internal table output for BDC
    data : begin of t_output occurs 0,
    bukrs type anla-bukrs,
    anln1 type anla-anln1,
    anln2 type anla-anln2,
    zugdt type anla-zugdt,
    result(70) type c,
    end of t_output.
    *****get data from loop********************************
      loop at t_anla.
        CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
             EXPORTING
                  INPUT  = t_anla-anln1
             IMPORTING
                  OUTPUT = t_anla-anln1.
        CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
             EXPORTING
                  INPUT  = t_anla-anln2
             IMPORTING
                  OUTPUT = t_anla-anln2.
    check record is correct or not
        select single bukrs anln1 anln2 zugdt
        into w_output
        from anla
        where bukrs = t_anla-bukrs and
        anln1 = t_anla-anln1 and
        anln2 = t_anla-anln2
       zugdt = '00000000'
    if record is correct
        if sy-subrc = 0 and w_output-zugdt = '00000000'.
          w_output-bukrs = t_anla-bukrs.
          w_output-anln1 = t_anla-anln1.
          w_output-anln2 = t_anla-anln2.
          w_output-result = 'Yes : this asset can delete'.
          append w_output to t_output.
    if record is not correct
        elseif sy-subrc = 0 and w_output-zugdt <> '00000000'.
    there is error record  this asset have value already
          v_have_error = 'X'.
          w_output-bukrs = t_anla-bukrs.
          w_output-anln1 = t_anla-anln1.
          w_output-anln2 = t_anla-anln2.
          w_output-result = 'Error : this asset have value already'.
          append w_output to t_output.
        else.
    there is error record this asset donot exist in table anla
          v_have_error = 'X'.
          w_output-bukrs = t_anla-bukrs.
          w_output-anln1 = t_anla-anln1.
          w_output-anln2 = t_anla-anln2.
          w_output-result = 'Error : this asset doest not exist'.
          append w_output to t_output.
        endif.
    *end of check record is correct or not
        clear w_output.
      endloop.
    ******************************show data in ALV***************************************************
    show data from file in ALV
      perform display_report_ALV.
    *&      Form  display_report_ALV
    form display_report_ALV.
      DATA: LT_FIELD_CAT TYPE SLIS_T_FIELDCAT_ALV,
          LT_EVENTS TYPE SLIS_T_EVENT,
          LV_REPID LIKE SY-REPID.
      PERFORM ALV_DEFINE_FIELD_CAT USING LT_FIELD_CAT.
      PERFORM ALV_HEADER_BUILD USING T_LIST_TOP_OF_PAGE[].
      PERFORM ALV_EVENTTAB_BUILD USING LT_EVENTS[].
      LV_REPID = SY-REPID.
      CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
           EXPORTING
                I_CALLBACK_PROGRAM = LV_REPID
                IT_FIELDCAT        = LT_FIELD_CAT
                I_SAVE             = 'A'
                IT_EVENTS          = LT_EVENTS[]
           TABLES
                T_OUTTAB           = t_output
           EXCEPTIONS
                PROGRAM_ERROR      = 1
                OTHERS             = 2.
      IF SY-SUBRC NE 0.
        WRITE: / 'Return Code : ', SY-SUBRC,
          'from FUNCTION REUSE_ALV_GRID_DISPLAY'.
      ENDIF.
    endform.
    *&      Form  alv_define_field_cat
          text
         -->P_LT_FIELD_CAT  text
    FORM ALV_DEFINE_FIELD_CAT USING  TB_FCAT TYPE SLIS_T_FIELDCAT_ALV.
      DATA: WA_FIELDCAT LIKE LINE OF TB_FCAT,
        LV_COL_POS TYPE I.
      DEFINE FIELD_CAT.
        CLEAR WA_FIELDCAT.
        ADD 1 TO LV_COL_POS.
        WA_FIELDCAT-FIELDNAME = &1.
        WA_FIELDCAT-REF_TABNAME = &2.
        WA_FIELDCAT-COL_POS = LV_COL_POS.
        WA_FIELDCAT-KEY = &3.
        WA_FIELDCAT-NO_OUT = &4.
        WA_FIELDCAT-REF_FIELDNAME = &5.
        WA_FIELDCAT-DDICTXT = 'M'.
        IF NOT &6 IS INITIAL.
          WA_FIELDCAT-SELTEXT_L = &6.
          WA_FIELDCAT-SELTEXT_M = &6.
          WA_FIELDCAT-SELTEXT_S = &6.
        ENDIF.
        WA_FIELDCAT-DO_SUM = &7.
        WA_FIELDCAT-OUTPUTLEN = &8.
        APPEND WA_FIELDCAT TO TB_FCAT.
      END-OF-DEFINITION.
      FIELD_CAT  'BUKRS'  'ANLA'     'X' '' 'BUKRS' 'Company Code' '' ''.
      FIELD_CAT  'ANLN1'  'ANLA'     'X' '' 'ANLN1' 'Asset Number' '' ''.
      FIELD_CAT  'ANLN2'  'ANLA'     'X' '' 'ANLN2' 'Asset Sub Number' '' ''.
    FIELD_CAT  'ATEXT'   'T5EAE'     'X' '' 'ATEXT' 'Result' '' ''.
      FIELD_CAT  'RESULT'  ''     'X' '' 'RESULT' 'RESULT' '' ''.
    ENDFORM.                    " alv_define_field_cat

    Hi,
    Check this code..
    FORM display_report_alv.
      DATA: lt_field_cat TYPE slis_t_fieldcat_alv,
      lt_events TYPE slis_t_event,
      lv_repid LIKE sy-repid.
      PERFORM alv_define_field_cat USING lt_field_cat.
      PERFORM alv_header_build USING t_list_top_of_page[].
      PERFORM alv_eventtab_build USING lt_events[].
      lv_repid = sy-repid.
      IF sy-batch EQ 'X'.  ----> " System Field for Backgroud..if Background use list display
        CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
          EXPORTING
            i_callback_program = lv_repid
            it_fieldcat        = lt_field_cat
            i_save             = 'A'
            it_events          = lt_events[]
          TABLES
            t_outtab           = t_output
          EXCEPTIONS
            program_error      = 1
            OTHERS             = 2.
      ELSE.
        CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
          EXPORTING
            i_callback_program = lv_repid
            it_fieldcat        = lt_field_cat
            i_save             = 'A'
            it_events          = lt_events[]
          TABLES
            t_outtab           = t_output
          EXCEPTIONS
            program_error      = 1
            OTHERS             = 2.
      ENDIF.
      IF sy-subrc NE 0.
        WRITE: / 'Return Code : ', sy-subrc,
        'from FUNCTION REUSE_ALV_GRID_DISPLAY'.
      ENDIF.
    ENDFORM.                    "display_report_ALV

  • Spool error for background job

    Hi All,
    I have scheduled one job in sap for a report.I have made a distribution list via tcode SO01.
    I have given this distribution list to the SPOOL RECEPIENT section in SM 36.
    The job is running successfully but is giving the following error and not sending emails to the distribution list.
    The error is :-
    "Spool list of step 1 could not be sent due to error 7".
    Does anybody has any idea about this error?
    Please help its a production issue.
    Thanks in advance
    Vivekanand Meghmala

    Look at SAP note : 760838
    Symptom
    Background job spool lists are not sent.
    Other terms
    RSBTCRTE, RSPO_SPOOLJOB_TO_OFFICE, SO_DOCUMENT_SEND_API1
    Reason and Prerequisites
    1. The jobs in question have recipient references in table TBTCO but these have no equivalent in the Business Object Repository.
    2. An error occurs when sending in the spool or in the Sapconnect layer.
    Solution
    This note does not provide a direct solution to the problem but it does provide a source code enhancement that you can use to create more trace information about the cause of the error. When you copy and execute a job with spool list recipients, trace messages are output when errors occur.
    After implementing the correction instructions, use transaction SE91 to create the following message:
    Message class: BT
    Number: 347
    Text: Spool list of step &1 could not be sent due to error &2.
    In detail, the error numbers mean:
    1 = Spool request does not exist (or no longer exists)
    2 = Spool request does not contain any data
    3 = Empty page area selected
    4 = No authorization to send the request
    5 = Access to the spool request is not possible
    6 = Read error in the Temse layer
    7 = Spool request could not be sent (sending problem)
    8 = Incorrect request type
    9 = Other

  • Not able to print to locl printer, spool request status is in wait

    Hi All,
    When user print to locl printer, the spool request is created and we get a error message saying "connection closed after (protocol) error (RC=1)". And we found the status of spool request is in wait state and if double clicked on it, it is showing "Internal error printing".
    Below is the log of Spool work process for your reference
    Found unqueued job 21701/1 (LOCL)
    ERROR => Printer LOCL: Lookup failed ?!?!? -> Status DELAY http://rspopcc. 0813
    Just to update you user is able to print all other documents except the documents from SAP application. And user is connecting to SAP application server through Citrix.
    We are on HP-UX, Oracle database and SAP R/3 3.1i version.
    Thanks in advance.
    Regards,
    Chandrika

    sundaresh suryanarayan wrote:
    Hello Chandrika,
    >
    > Is this printer is a network printer ?.   Use Device Type : SWIN and Access Method : G Front End Printing .  
    >
    > Thanks
    >
    > Sundaresh Suryanarayan
    Hi Sundaresh,
    Thanks for your reply.
    Yes it is a network printer. User is printing to his default printer(LOCL, with host printer __DEFAULT) and we are using  device type SAPWIN and access method F(printing on front end computer).
    Regards,
    Chandrika

  • Spool list for Background job

    Dear all ,
    The background job is already scheduled daily (PR NOT PROCESSED BY PURCHASING) , isn't possible to check the list of users is assigned in the spool list recipiant, I have checked spool list , but its shows only one id ....
    how to check the list of Spool users ...any alternate option ?
    Kindly advise
    Regards

    Hi ,
    I have created a distribution list and i have included  the email ids also .
    any other activation is required for Distribution list ?
    how the background job is sending a report to Distribution list or i have to assign a distribution list to Background job .
    Kindly suggest
    Regards

  • How to print Spool requests for cheque printing sequentially

    Dear All,
    I am making vendor payments and printing cheques using F-58. It automatically creates a spool requests at the end of the transaction. When i complete all my payments and go to SP01 for viewing spool requests, the last request appears at the top of the list.
    If i select 3 consecutive requests and print them at a time, the last request gets printed first on the first cheque number and the first request gets printed on the last cheque number.
    This results in anomaly in the cheque number assigned in the system and the printed cheque as the last payment is printed on the first cheque.
    I am using dot matrix printer with  page format fixed for cheque specifications. The cheques are printed properly as per the format except the order of printing.
    Kindly let me know how to print multiple requests sequentially from the spool requests list such that the spool request number printed matches with the serial cheque numbers.
    Regards,
    SAP_2009

    Hi,
    I understod your issue.
    Whenever you posted multiple payment documents, and after that if you want to take cheque printouts sequentially by using more spool requests.........there is a way to sort out this issue.
    1) Select all of your spool requests and click on Sort in ascending Order (CtrlShiftF5) and click on Print directly (CtrlShiftF8). By doing this you will get the cheque printouts sequentially according to your payment document sequence.
    Hope this will help you
    Assign ********, if it solved your problem.
    Thanks,
    Srinu

  • Spool incomplete through background job

    Hi All,
    A spool is being created through a background job which is displaying strangely.
    CONCATENATE text-t01 co_constant v_variable text-t02 INTO v_output.
    CONCATENATE text-t03 text-t04 INTO v_output2.
    WRITE: / v_output1,
                / v_output2.
    In integration system, everything is comign fine. But in production system, only v_variable in v_output is being displayed. None of the text elements are being displayed. We checked the text elements translation and all. Everything is perfect.
    Can anybody suggest on this?
    Thanks!!!

    Hi Srinivas,
    Please check those text elements has transported to the Production server or not
    or else double click on the text element to check that text elements are currently in the production server.
    If not then transport those text elements again and make sure that they are in Production system.
    Regards,
    Md Ziauddin.

  • Print the order with Background Job

    Hi Gurus,
    I have to print the order on button click in a report.
    i have done the coding and passing the parameters to a stahndard program on  submit.
    but problem is that order is going to spool but not printing the order.
    As batch job not supporting the LOCL,please suggect the alternative to achieve the print.
    Br,
    Surya

    Hi Lokesh,
    Thanks for your quick reply.
    i am using the below code for printing the order with batch job on clicking the button in my report.
         DATA: NAME TYPE TBTCJOB-JOBNAME.
    DATA: NUMBER  TYPE TBTCJOB-JOBCOUNT.
    DATA: PRINT_PARAMETERS TYPE PRI_PARAMS.
    NAME = 'ORDER_PRINTING'.
    CLEAR: RANGE1.
    *REFRESH: range.
    RANGE1-SIGN = 'I'.
    RANGE1-OPTION = 'EQ'.
    RANGE1-LOW = 'BA00'.
    RANGE1-HIGH = 'ZBA1'.
    APPEND RANGE1 TO RANGE.             .
    CALL FUNCTION 'JOB_OPEN'
    EXPORTING
    JOBNAME = NAME
    IMPORTING
    JOBCOUNT         = NUMBER
    EXCEPTIONS
    CANT_CREATE_JOB  = 1
    INVALID_JOB_DATA = 2
    JOBNAME_MISSING  = 3
    OTHERS = 4.
    IF SY-SUBRC = 0.
    SUBMIT SD70AV1A WITH  RG_KSCHL IN RANGE
      WITH  RG_VBELN IN ORDER_TAB
      TO SAP-SPOOL
      SPOOL PARAMETERS PRINT_PARAMETERS
      WITHOUT SPOOL DYNPRO
      VIA JOB NAME NUMBER NUMBER
      AND RETURN.
    IF SY-SUBRC = 0.
    CALL FUNCTION 'JOB_CLOSE'
    EXPORTING
    JOBCOUNT = NUMBER
    JOBNAME = NAME
    STRTIMMED = 'X'
    EXCEPTIONS
    CANT_START_IMMEDIATE = 1
    INVALID_STARTDATE = 2
    JOBNAME_MISSING = 3
    JOB_CLOSE_FAILED = 4
    JOB_NOSTEPS = 5
    JOB_NOTEX = 6
    LOCK_FAILED = 7
    OTHERS = 8.
    IF SY-SUBRC <> 0.
    ENDIF.
    ENDIF.
    Please suggest where should i give the printer name.
    fyi.. i am trying to pass the same LOCL name to the job with the FM- GET_PRINT_PARAMETERS with destinamtion 'LOCL'
    Br,
    Surya

  • Print error scheduling a background job

    HI
    I am using
    Transaction F110 – Automatic Payment.
    When I am scheduling job for printing in background,I am getting error
    The error <Status Text in spool > states front end unavailable.
    Any inputs asap pls

    You are getting the error because, the printer selected to print the output trying to use front end default printer. You might have selected LOCL as the printer. Chage the printer.
    Regards
    Sridhar

  • Printing of Invoices during background Jobs

    Hello,
    We have an o/p type that is processed each time a billing document is created. The o/p type prints the billing document as soon as it is saved. When we have a billing due list program run in background the printouts are waiting in the Spool and are not printed. Is there any way we can print the documents when the billing due list program runs in background.
    Any help would be appreciated.
    Thanks,
    Alam.

    Hello Alam,
    If your question was answered, please close this thread and assign the points to the person that give you the answer.
    Regards,
    Eric

  • BackGround Job's Spool Request is having "Waiting" "Frontend unavailable"

    Hello Friends,
    I am facing one problem related to Spool Request, which is generated through Scheduled Background Jobs (scheduled by funcional people).
    The Background Job is having status "completed" when analyzing it. But, its associated Spool Request is showing "waiting" Status, with "Frontend unavailable" as Status Text.
    Here is the brief status of that Spool Request.
    28448     1      300 USER1 00:00 LP01 X_65_80      Frontend unavailable
    in Detail:
    Description          Value
    Status:              Frontend unavailable
    Last event:
    Message:             Request on hold
    Date:                01.07.2009
    Time:                00:00:27
    Job status:          On hold
    Error class:         Delayed
    Area:                Data transfer
    Printout:            Not printed
    The Setting of LP01 O/Device is as followed:
    Output Device        LP01
    Device Type        SWIN SWIN  : Windows printing via SAPlpd
    Device Class      Standard Printer
    Host Spool Access Method       F F: Printing on Front End Computer
    Host printer                     __DEFAULT
    Moreover, the SAP User USER1 is allocated LP01 as Output Device with "Output Immediately" & "Delete After Output" checked status.
    Some Background Jobs are showing the same status for this LP01.
    I have a doubt on allocated O/P Device LP01.
    Any Clue for this issue ?
    Regards,
    Bhavik G. Shroff

    Hello Markus,
    Here , in our Landscape , there is not Print Server. All are taking prints through, Networked Printer and their local connected Printers.
    Can i configure "send to SAP Spooler for now" instead of "Print Immediately "in the Print Specification of those Background Jobs ?
    Moreover, Some Background jobs are sending E-Mails with the processed Reports as an Attachments. They are showing sometime unexpected behavior, in sending emails,  although there is no relation is with this Printing related issue.
    When i am looking into "Overview of Send Orders" of SCOT, some Background Jobs are showing success for sending emails, and some are not showing success, even though All the recipients are same for the scheduled Background Jobs which are running on same time.
    Regards,
    Bhavik G. Shroff

  • Is it possible to have Multiple Spool requests in one batch job overview?

    Hi,
    While running one of my z program in back ground, there are two spools generated (one by write statement and one by OPEN_FORM statement and both the spools are available in SP01 Transaction), but when i see the job overview in transaction SM37, I only see one spool request (that of the last spool request). Can any body in the group please tell me is it possible to see multiple spool requests in the job overview of one Abap program and if yes, how?
    Thank you.
    Abinash

    Hi Jayanthi,
    Thank you for the link. But probably that discussion was also an unsolved one.
    Anyway, does any one in the group think that display of multiple spools per one step job is dependent on client / SAP Server setting? Because as evident from the chain of mails in the link provided by Jayanthi, some people say that they see multiple spool requests for one program in batch mode job overview (SM37)? If yes, can some body tell me the required configuration?

  • Delete Spools created by one background job

    Hi ,
    I have a background job which runs every now and then and it creates spools. My requirement is to delete all spools created by this one job only in regular intervals via another program.
    Regards,
    Arun.

    Hi J@Y,
    the spools that my background job is creating should stay in the system for a while for users to go and see it. After a specific interval, say every 30 minutes, i want all the spools created by that one job till that time to be deleted
    regards,
    Arun.

  • OfficeJet Pro L7780 - Have to Restart Print Spooler every job I print (Windows 7 32-bit)

    I have an OfficeJet Pro L7780 that shows as offline in Devices and Printers constantly.  I discovered if I queue up print jobs to it and then restart the print spooler all of the jobs will come out perfectly then the printer will instantly go offline.   Here is what I've done for troubleshooting already:
    Upgrade to newest firmware (R2011NxNxeN0)
    Factory Reset by hold # and 3 at boot
    Changed Ink and Print Heads
    Installed newest 14.0 driver (tried both Basic and IT Pro Driver)
    Rebooted and restarted printer and computer
    Tried all this on a 2nd Windows 7 computer with the same results
    Anyone actually use this printer on Windows 7 32-bit over the wired network port!!?!
    This question was solved.
    View Solution.

    Same printer, same problem, same remediation by restarting Printer Spooler service.  Only difference is OS is Win 7 Ultimate 64-bit.
    FYI- I'm using my L7780 via a wifi connection using WPA2 security and a static IP and network RAW printing to port 9100.  The printer always appears available via network pings but not to the print spooler.  As such, printer is always "grayed out" and disabled but will accept jobs into its queue.
    After endless searching this is what appears to be working as a fix:  Turn off SNMP on printer port.
    Printer Properties -> Ports Tab -> (Select Port) -> Configure Port -> uncheck "SNMP Status Enabled"
    Hopefully this works for others- but I also found mention that others found a fix in toggling other settings such as "Enable bidirection printing" check box.  Who knows what seemingly unrelated software triggers this issue but it began one strange day and drove me crazy.

Maybe you are looking for