Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Spool not generating

former_member187452
Contributor
0 Kudos

Hi,

I have below piece of code. can you please let me know what is wrong in this code. it is not generating spool.



    CALL FUNCTION 'GET_PRINT_PARAMETERS'
      EXPORTING
        archive_mode           = '1'
        mode                   = 'BATCH'
        no_dialog              = 'X'
        report                 = 'RPRCCC00'
      IMPORTING
        out_parameters         = lwa_para
      EXCEPTIONS
        archive_info_not_found = 1
        invalid_print_params   = 2
        invalid_archive_params = 3
        OTHERS                 = 4.
    IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.

    CALL FUNCTION 'JOB_OPEN'
      EXPORTING
        jobname          = 'RPRCCC00'
      IMPORTING
        jobcount         = lv_jobcnt
      EXCEPTIONS
        cant_create_job  = 1
        invalid_job_data = 2
        jobname_missing  = 3
        OTHERS           = 4.
    IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.

    SUBMIT rprccc00
           WITH firmennr   EQ p_compid
           WITH testlauf   EQ c_test
           WITH bel_clus   EQ r_clus
           WITH bel_none   EQ r_none
           WITH bel_einf   EQ r_einf
           WITH file_in EQ lv_output
           TO SAP-SPOOL SPOOL PARAMETERS lwa_para WITHOUT SPOOL DYNPRO
           USER sy-uname
           VIA JOB 'RPRCCC00'
           NUMBER lv_jobcnt
           AND RETURN.

    COMMIT WORK AND WAIT.

    CALL FUNCTION 'JOB_CLOSE'
      EXPORTING
        jobcount             = lv_jobcnt
        jobname              = 'RPRCCC00'
        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
        invalid_target       = 8
        OTHERS               = 9.
    IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.


1 REPLY 1

former_member187452
Contributor
0 Kudos

Solved.

As there was issue in program.

Thanks