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: 

How to convert spool request to OTF

jiri_faltin2
Explorer
0 Kudos

Hello experts,

I need to convert spool request to OTF table. I found only some FM to convert spool request to PDF.

Is there some possible solution?

Thanks&regards,

Jirka Faltin

6 REPLIES 6

Former Member
0 Kudos

Hi,

You can use the FM RSPO_RETURN_SPOOLJOB and specify the type as OTF to get the OTF data from spool.

Vikranth

0 Kudos

Hello,

thjanks for help, unfortunatelly this FM is going to short dump every time. I have read note 690074, where I found, that this FM cannot be used in release higher than 4.6D. Do you have any other idea, how to get otf from spool job?

Thanks&regards,

Jirka Faltin

0 Kudos

Hi,

I am not aware of any other method. You could contact your BASIS team and download the corrections as mentioned in the Note

Vikranth

venkat_o
Active Contributor
0 Kudos

Hi, Try this way.


DATA:it_otf like soli occurs 0 with header line
CALL FUNCTION 'RSPO_RETURN_SPOOLJOB'
  EXPORTING
    rqident              = spool_no
    desired_type         = 'OTF'
  TABLES
    buffer               = it_otf
  EXCEPTIONS
    no_such_job          = 1
    job_contains_no_data = 2
    selection_empty      = 3
    no_permission        = 4
    can_not_access       = 5
    read_error           = 6
    type_no_match        = 7
    OTHERS               = 8.
Thanks Venkat.O

Former Member
0 Kudos

Hi,


*---convert spool to OTF
CALL FUNCTION 'RSPO_RETURN_SPOOLJOB'
    EXPORTING
      RQIDENT              = SPOOL1
    TABLES
      BUFFER               = TAB
    EXCEPTIONS
      NO_SUCH_JOB          = 1
      JOB_CONTAINS_NO_DATA = 2
      SELECTION_EMPTY      = 3
      NO_PERMISSION        = 4
      CAN_NOT_ACCESS       = 5
      READ_ERROR           = 6
      TYPE_NO_MATCH        = 7
      OTHERS               = 8.

      LOOP AT TAB.
        CLEAR OTF.
        OTF = TAB.
        APPEND OTF.
      ENDLOOP.

*---Convert OTF into PDF
      CALL FUNCTION 'CONVERT_OTF_2_PDF'
        EXPORTING
          USE_OTF_MC_CMD         = 'X'
        IMPORTING
          BIN_FILESIZE           = SIZE
        TABLES
          OTF                    = OTF
          DOCTAB_ARCHIVE         = DOC
          LINES                  = PDF
        EXCEPTIONS
          ERR_CONV_NOT_POSSIBLE  = 1
          ERR_OTF_MC_NOENDMARKER = 2
          OTHERS                 = 3.

Thanks,

Krishna

Former Member
0 Kudos

This message was moderated.