OUT PUT ERROR

HI 
    WHEN I AM EXECUTING THE FOLLOWING PROG I AM GETTING AN ERROR "MAXIMUM NUMBER OF INTERNAL SESSIONS REACHED".
DOES ANY ONE HAS ANY IDEA ABT IT.
REPORT  ZSPOOL14.
TABLES:TSP01.
PARAMETERS: P_EMAIL1 LIKE SOMLRECI1-RECEIVER,
            P_EMAIL2 LIKE SOMLRECI1-RECEIVER,
            P_EMAIL3 LIKE SOMLRECI1-RECEIVER,
           P_SENDER LIKE SOMLRECI1-RECEIVER,
            P_DELSPL AS CHECKBOX.
*DATA DECLARATION
DATA: GD_RECSIZE TYPE I.
Spool IDs
TYPES: BEGIN OF T_TBTCP.
        INCLUDE STRUCTURE TBTCP.
TYPES: END OF T_TBTCP.
DATA: IT_TBTCP TYPE STANDARD TABLE OF T_TBTCP INITIAL SIZE 0,
      WA_TBTCP TYPE T_TBTCP.
Job Runtime Parameters
DATA: GD_EVENTID LIKE TBTCM-EVENTID,
      GD_EVENTPARM LIKE TBTCM-EVENTPARM,
      GD_EXTERNAL_PROGRAM_ACTIVE LIKE TBTCM-XPGACTIVE,
      GD_JOBCOUNT LIKE TBTCM-JOBCOUNT,
      GD_JOBNAME LIKE TBTCM-JOBNAME,
      GD_STEPCOUNT LIKE TBTCM-STEPCOUNT,
      GD_ERROR    TYPE SY-SUBRC,
      GD_RECIEVER TYPE SY-SUBRC.
DATA:  W_RECSIZE TYPE I.
DATA: GD_SUBJECT   LIKE SODOCCHGI1-OBJ_DESCR,
      IT_MESS_BOD LIKE SOLISTI1 OCCURS 0 WITH HEADER LINE,
      IT_MESS_ATT LIKE SOLISTI1 OCCURS 0 WITH HEADER LINE,
      GD_SENDER_TYPE     LIKE SOEXTRECI1-ADR_TYP,
      GD_ATTACHMENT_DESC TYPE SO_OBJ_NAM,
      GD_ATTACHMENT_NAME TYPE SO_OBJ_DES.
Spool to PDF conversions
DATA: GD_SPOOL_NR LIKE TSP01-RQIDENT,
      GD_DESTINATION LIKE RLGRAP-FILENAME,
      GD_BYTECOUNT LIKE TST01-DSIZE,
      GD_BUFFER TYPE STRING.
Binary store for PDF
DATA: BEGIN OF IT_PDF_OUTPUT OCCURS 0.
        INCLUDE STRUCTURE TLINE.
DATA: END OF IT_PDF_OUTPUT.
CONSTANTS:C_DEV LIKE  SY-SYSID VALUE 'DEV',
          C_NO(1)  TYPE C   VALUE ' ',
          C_DEVICE(4) TYPE C   VALUE 'LOCL'.
print parameters
DATA:PARAMS LIKE PRI_PARAMS,
DAYS(1)  TYPE N VALUE 2,
COUNT(3) TYPE N VALUE 1,
VALID TYPE C,
SPOOL_REQUEST_NAME LIKE PRI_PARAMS-PLIST.
*INITIALIZATION.
P_EMAIL1 = '[email protected]'.
*START-OF-SELECTION.
START-OF-SELECTION.
Write statement to represent report output. Spool request is created
if write statement is executed in background. This could also be an
ALV grid which would be converted to PDF without any extra effort
  WRITE 'HAI EVERYONE'.
  NEW-PAGE.
  COMMIT WORK.
NEW-PAGE PRINT OFF.
  CONCATENATE SY-REPID+0(8)
  SY-UNAME+0(3)
  INTO SPOOL_REQUEST_NAME SEPARATED BY '_'.
  CALL FUNCTION 'GET_PRINT_PARAMETERS'
EXPORTING
     ARCHIVE_MODE                   = '1'
  ARCHIVE_TEXT                   = C_CHAR_UNKNOWN
  AR_OBJECT                      = C_CHAR_UNKNOWN
  ARCHIVE_REPORT                 = C_CHAR_UNKNOWN
  AUTHORITY                      = C_CHAR_UNKNOWN
     COPIES                         = COUNT
     COVER_PAGE                     = ''
  DATA_SET                       = C_CHAR_UNKNOWN
  DEPARTMENT                     = C_CHAR_UNKNOWN
     DESTINATION                    = 'HR04'
     EXPIRATION                     = DAYS
     IMMEDIATELY                    = ''
  IN_ARCHIVE_PARAMETERS          = ' '
  IN_PARAMETERS                  = ' '
     LAYOUT                         = 'X_65_32'
     LINE_COUNT                     = 65
     LINE_SIZE                      = 132
     LIST_NAME                      = SPOOL_REQUEST_NAME
  LIST_TEXT                      = C_CHAR_UNKNOWN
     MODE                           = 'BATCH'
     NEW_LIST_ID                    = 'X'
  PROTECT_LIST                   = C_CHAR_UNKNOWN
     NO_DIALOG                      = 'X'
     RECEIVER                       = ''
  RELEASE                        = ''
     REPORT                         = ''
     SAP_COVER_PAGE                 = 'D'
     HOST_COVER_PAGE                = 'D'
  PRIORITY                       = C_NUM1_UNKNOWN
  SAP_OBJECT                     = C_CHAR_UNKNOWN
  TYPE                           = C_CHAR_UNKNOWN
  USER                           = SY-UNAME
  USE_OLD_LAYOUT                 = ' '
  UC_DISPLAY_MODE                = C_CHAR_UNKNOWN
  DRAFT                          = C_CHAR_UNKNOWN
  ABAP_LIST                      = ' '
  USE_ARCHIVENAME_DEF            = ' '
  DEFAULT_SPOOL_SIZE             = C_CHAR_UNKNOWN
  PO_FAX_STORE                   = ' '
  NO_FRAMES                      = C_CHAR_UNKNOWN
   IMPORTING
  OUT_ARCHIVE_PARAMETERS         =
     OUT_PARAMETERS                 = PARAMS
     VALID                          = VALID
  VALID_FOR_SPOOL_CREATION       =
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.
  IF VALID <> SPACE.
    SUBMIT ZSPOOL14 TO SAP-SPOOL
    SPOOL PARAMETERS PARAMS
    WITHOUT SPOOL DYNPRO AND RETURN.
  ENDIF.
  IF SY-BATCH EQ 'X'.
    PERFORM GET_JOB_DETAILS.
    PERFORM OBTAIN_SPOOL_ID.
Alternative way could be to submit another program and store spool
id into memory.
*submit ZSPOOLTOPDF2
       to sap-spool
       spool parameters   %_print
       archive parameters %_print
       without spool dynpro
       and return.
Get spool id from program called above
IMPORT w_spool_nr FROM MEMORY ID 'SPOOLTOPDF'.
    PERFORM CONVERT_SPOOL_TO_PDF.
    PERFORM PROCESS_EMAIL.
    IF P_DELSPL EQ 'X'.
      PERFORM DELETE_SPOOL.
    ENDIF.
    IF SY-SYSID = C_DEV.
      WAIT UP TO 5 SECONDS.
      SUBMIT RSCONN01 WITH MODE   = 'INT'
                      WITH OUTPUT = 'X'
                      AND RETURN.
    ENDIF.
  ELSE.
    PERFORM FCONVERT_SPOOL_TO_PDF.
    PERFORM PROCESS_EMAIL.
    IF P_DELSPL EQ 'X'.
      PERFORM DELETE_SPOOL.
    ENDIF.
    IF SY-SYSID = C_DEV.
      WAIT UP TO 5 SECONDS.
      SUBMIT RSCONN01 WITH MODE   = 'INT'
                      WITH OUTPUT = 'X'
                      AND RETURN.
    ENDIF.
   SKIP.
   WRITE:/ 'Program must be executed in background in-order for spool'
           'request to be created.'.
  ENDIF.
      FORM obtain_spool_id                                          *
FORM OBTAIN_SPOOL_ID.
  CHECK NOT ( GD_JOBNAME IS INITIAL ).
  CHECK NOT ( GD_JOBCOUNT IS INITIAL ).
  SELECT * FROM  TBTCP
                 INTO TABLE IT_TBTCP
                 WHERE      JOBNAME     = GD_JOBNAME
                 AND        JOBCOUNT    = GD_JOBCOUNT
                 AND        STEPCOUNT   = GD_STEPCOUNT
                 AND        LISTIDENT   <> '0000000000'
                 ORDER BY   JOBNAME
                            JOBCOUNT
                            STEPCOUNT.
  READ TABLE IT_TBTCP INTO WA_TBTCP INDEX 1.
  IF SY-SUBRC = 0.
   MESSAGE S004(ZDD) WITH GD_SPOOL_NR.
    GD_SPOOL_NR = WA_TBTCP-LISTIDENT.
   MESSAGE S004(ZDD) WITH GD_SPOOL_NR.
  ELSE.
    MESSAGE S005(ZDD).
  ENDIF.
ENDFORM.                    "obtain_spool_id
      FORM get_job_details                                          *
FORM GET_JOB_DETAILS.
Get current job details
  CALL FUNCTION 'GET_JOB_RUNTIME_INFO'
    IMPORTING
      EVENTID                 = GD_EVENTID
      EVENTPARM               = GD_EVENTPARM
      EXTERNAL_PROGRAM_ACTIVE = GD_EXTERNAL_PROGRAM_ACTIVE
      JOBCOUNT                = GD_JOBCOUNT
      JOBNAME                 = GD_JOBNAME
      STEPCOUNT               = GD_STEPCOUNT
    EXCEPTIONS
      NO_RUNTIME_INFO         = 1
      OTHERS                  = 2.
ENDFORM.                    "get_job_details
      FORM convert_spool_to_pdf                                     *
FORM CONVERT_SPOOL_TO_PDF.
  CALL FUNCTION 'CONVERT_ABAPSPOOLJOB_2_PDF'
    EXPORTING
      SRC_SPOOLID              = GD_SPOOL_NR
      NO_DIALOG                = C_NO
      DST_DEVICE               = C_DEVICE
    IMPORTING
      PDF_BYTECOUNT            = GD_BYTECOUNT
    TABLES
      PDF                      = IT_PDF_OUTPUT
    EXCEPTIONS
      ERR_NO_ABAP_SPOOLJOB     = 1
      ERR_NO_SPOOLJOB          = 2
      ERR_NO_PERMISSION        = 3
      ERR_CONV_NOT_POSSIBLE    = 4
      ERR_BAD_DESTDEVICE       = 5
      USER_CANCELLED           = 6
      ERR_SPOOLERROR           = 7
      ERR_TEMSEERROR           = 8
      ERR_BTCJOB_OPEN_FAILED   = 9
      ERR_BTCJOB_SUBMIT_FAILED = 10
      ERR_BTCJOB_CLOSE_FAILED  = 11
      OTHERS                   = 12.
  CHECK SY-SUBRC = 0.
Transfer the 132-long strings to 255-long strings
  LOOP AT IT_PDF_OUTPUT.
    TRANSLATE IT_PDF_OUTPUT USING ' ~'.
    CONCATENATE GD_BUFFER IT_PDF_OUTPUT INTO GD_BUFFER.
  ENDLOOP.
  TRANSLATE GD_BUFFER USING '~ '.
  DO.
    IT_MESS_ATT = GD_BUFFER.
    APPEND IT_MESS_ATT.
    SHIFT GD_BUFFER LEFT BY 255 PLACES.
    IF GD_BUFFER IS INITIAL.
      EXIT.
    ENDIF.
  ENDDO.
ENDFORM.                    "convert_spool_to_pdf
      FORM process_email                                            *
FORM PROCESS_EMAIL.
  DESCRIBE TABLE IT_MESS_ATT LINES GD_RECSIZE.
  CHECK GD_RECSIZE > 0.
  PERFORM SEND_EMAIL USING P_EMAIL1 P_EMAIL2 P_EMAIL3.
perform send_email using p_email2.
ENDFORM.                    "process_email
      FORM send_email                                               *
-->  p_email                                                       *
FORM SEND_EMAIL USING P_EMAIL P_EMAIL4 P_EMAIL5.
  CHECK NOT ( P_EMAIL IS INITIAL ).
  CHECK NOT ( P_EMAIL4 IS INITIAL ).
  CHECK NOT ( P_EMAIL5 IS INITIAL ).
  REFRESH IT_MESS_BOD.
Default subject matter
  GD_SUBJECT         = 'Subject'.
  GD_ATTACHMENT_DESC = 'Attachname'.
  CONCATENATE 'ebdit' ' ' INTO GD_ATTACHMENT_NAME.
  IT_MESS_BOD        = 'Message Body text, line 1'.
  APPEND IT_MESS_BOD.
  IT_MESS_BOD        = 'Message Body text, line 2...'.
  APPEND IT_MESS_BOD.
If no sender specified - default blank
IF P_SENDER EQ SPACE.
   GD_SENDER_TYPE  = SPACE.
ELSE.
   GD_SENDER_TYPE  = 'INT'.
ENDIF.
Send file by email as .xls speadsheet
  PERFORM SEND_FILE_AS_EMAIL_ATTACHMENT
                               TABLES IT_MESS_BOD
                                      IT_MESS_ATT
                                USING P_EMAIL
                                      P_EMAIL4
                                      P_EMAIL5
                                      'ebdit output'
                                      'PDF'
                                      GD_ATTACHMENT_NAME
                                      GD_ATTACHMENT_DESC
                                     P_SENDER
                                      GD_SENDER_TYPE
                             CHANGING GD_ERROR
                                      GD_RECIEVER.
ENDFORM.                    "send_email
      FORM delete_spool                                             *
FORM DELETE_SPOOL.
  DATA: LD_SPOOL_NR TYPE TSP01_SP0R-RQID_CHAR.
  LD_SPOOL_NR = GD_SPOOL_NR.
  CHECK P_DELSPL <> C_NO.
  CALL FUNCTION 'RSPO_R_RDELETE_SPOOLREQ'
    EXPORTING
      SPOOLID = LD_SPOOL_NR.
ENDFORM.                    "delete_spool
*&      Form  SEND_FILE_AS_EMAIL_ATTACHMENT
      Send email
FORM SEND_FILE_AS_EMAIL_ATTACHMENT TABLES IT_MESSAGE
                                          IT_ATTACH
                                    USING P_EMAIL
                                          P_EMAIL4
                                          P_EMAIL5
                                          P_MTITLE
                                          P_FORMAT
                                          P_FILENAME
                                          P_ATTDESCRIPTION
                                         P_SENDER_ADDRESS
                                          P_SENDER_ADDRES_TYPE
                                 CHANGING P_ERROR
                                          P_RECIEVER.
  DATA: LD_ERROR    TYPE SY-SUBRC,
        LD_RECIEVER TYPE SY-SUBRC,
        LD_MTITLE LIKE SODOCCHGI1-OBJ_DESCR,
        LD_EMAIL1 LIKE  SOMLRECI1-RECEIVER,
        LD_EMAIL2 LIKE  SOMLRECI1-RECEIVER,
        LD_EMAIL3 LIKE  SOMLRECI1-RECEIVER,
        LD_FORMAT TYPE  SO_OBJ_TP ,
        LD_ATTDESCRIPTION TYPE  SO_OBJ_NAM ,
        LD_ATTFILENAME TYPE  SO_OBJ_DES ,
        LD_SENDER_ADDRESS LIKE  SOEXTRECI1-RECEIVER,
        LD_SENDER_ADDRESS_TYPE LIKE  SOEXTRECI1-ADR_TYP,
        LD_RECEIVER LIKE  SY-SUBRC.
  DATA:   T_PACKING_LIST LIKE SOPCKLSTI1 OCCURS 0 WITH HEADER LINE,
          T_CONTENTS LIKE SOLISTI1 OCCURS 0 WITH HEADER LINE,
          T_RECEIVERS LIKE SOMLRECI1 OCCURS 0 WITH HEADER LINE,
          T_ATTACHMENT LIKE SOLISTI1 OCCURS 0 WITH HEADER LINE,
          T_OBJECT_HEADER LIKE SOLISTI1 OCCURS 0 WITH HEADER LINE,
          W_CNT TYPE I,
          W_SENT_ALL(1) TYPE C,
          W_DOC_DATA LIKE SODOCCHGI1.
  LD_EMAIL1   = P_EMAIL.
  LD_EMAIL2   = P_EMAIL4.
  LD_EMAIL3   = P_EMAIL5.
  LD_MTITLE = P_MTITLE.
  LD_FORMAT              = P_FORMAT.
  LD_ATTDESCRIPTION      = P_ATTDESCRIPTION.
  LD_ATTFILENAME         = P_FILENAME.
LD_SENDER_ADDRESS      = P_SENDER_ADDRESS.
  LD_SENDER_ADDRESS_TYPE = P_SENDER_ADDRES_TYPE.
Fill the document data.
  W_DOC_DATA-DOC_SIZE = 1.
Populate the subject/generic message attributes
  W_DOC_DATA-OBJ_LANGU = SY-LANGU.
  W_DOC_DATA-OBJ_NAME  = 'SAPRPT'.
  W_DOC_DATA-OBJ_DESCR = LD_MTITLE .
  W_DOC_DATA-SENSITIVTY = 'F'.
Fill the document data and get size of attachment
  CLEAR W_DOC_DATA.
  READ TABLE IT_ATTACH INDEX W_CNT.
  W_DOC_DATA-DOC_SIZE =
     ( W_CNT - 1 ) * 255 + STRLEN( IT_ATTACH ).
  W_DOC_DATA-OBJ_LANGU  = SY-LANGU.
  W_DOC_DATA-OBJ_NAME   = 'SAPRPT'.
  W_DOC_DATA-OBJ_DESCR  = LD_MTITLE.
  W_DOC_DATA-SENSITIVTY = 'F'.
  CLEAR T_ATTACHMENT.
  REFRESH T_ATTACHMENT.
  T_ATTACHMENT[] = IT_ATTACH[].
Describe the body of the message.
  CLEAR T_PACKING_LIST.
  REFRESH T_PACKING_LIST.
  T_PACKING_LIST-TRANSF_BIN = SPACE.
  T_PACKING_LIST-HEAD_START = 1.
  T_PACKING_LIST-HEAD_NUM = 0.
  T_PACKING_LIST-BODY_START = 1.
  DESCRIBE TABLE IT_MESSAGE LINES T_PACKING_LIST-BODY_NUM.
T_PACKING_LIST-DOC_TYPE = 'RAW'.
  APPEND T_PACKING_LIST.
Create attachment notification
  T_PACKING_LIST-TRANSF_BIN = 'X'.
  T_PACKING_LIST-HEAD_START = 1.
  T_PACKING_LIST-HEAD_NUM   = 1.
  T_PACKING_LIST-BODY_START = 1.
  DESCRIBE TABLE T_ATTACHMENT LINES T_PACKING_LIST-BODY_NUM.
  T_PACKING_LIST-DOC_TYPE   =  LD_FORMAT.
  T_PACKING_LIST-OBJ_DESCR  =  LD_ATTDESCRIPTION.
  T_PACKING_LIST-OBJ_NAME   =  LD_ATTFILENAME.
  T_PACKING_LIST-DOC_SIZE   =  T_PACKING_LIST-BODY_NUM * 255.
  APPEND T_PACKING_LIST.
Add the recipients email address
  CLEAR T_RECEIVERS.
  REFRESH T_RECEIVERS.
  T_RECEIVERS-RECEIVER = LD_EMAIL1.
  T_RECEIVERS-REC_TYPE = 'U'.
  T_RECEIVERS-COM_TYPE = 'INT'.
  T_RECEIVERS-NOTIF_DEL = 'X'.
  T_RECEIVERS-NOTIF_NDEL = 'X'.
  APPEND T_RECEIVERS.
  CLEAR T_RECEIVERS.
REFRESH T_RECEIVERS.
  T_RECEIVERS-RECEIVER = LD_EMAIL2.
  T_RECEIVERS-REC_TYPE = 'U'.
  T_RECEIVERS-COM_TYPE = 'INT'.
  T_RECEIVERS-NOTIF_DEL = 'X'.
  T_RECEIVERS-NOTIF_NDEL = 'X'.
  APPEND T_RECEIVERS.
  CLEAR T_RECEIVERS.
REFRESH T_RECEIVERS.
  T_RECEIVERS-RECEIVER = LD_EMAIL3.
  T_RECEIVERS-REC_TYPE = 'U'.
  T_RECEIVERS-COM_TYPE = 'INT'.
  T_RECEIVERS-NOTIF_DEL = 'X'.
  T_RECEIVERS-NOTIF_NDEL = 'X'.
  APPEND T_RECEIVERS.
  CALL FUNCTION 'SO_DOCUMENT_SEND_API1'
    EXPORTING
      DOCUMENT_DATA              = W_DOC_DATA
      PUT_IN_OUTBOX              = 'X'
     SENDER_ADDRESS             = LD_SENDER_ADDRESS
      SENDER_ADDRESS_TYPE        = LD_SENDER_ADDRESS_TYPE
      COMMIT_WORK                = 'X'
    IMPORTING
      SENT_TO_ALL                = W_SENT_ALL
    TABLES
      PACKING_LIST               = T_PACKING_LIST
      CONTENTS_BIN               = T_ATTACHMENT
     CONTENTS_TXT               = IT_MESSAGE
      RECEIVERS                  = T_RECEIVERS
    EXCEPTIONS
      TOO_MANY_RECEIVERS         = 1
      DOCUMENT_NOT_SENT          = 2
      DOCUMENT_TYPE_NOT_EXIST    = 3
      OPERATION_NO_AUTHORIZATION = 4
      PARAMETER_ERROR            = 5
      X_ERROR                    = 6
      ENQUEUE_ERROR              = 7
      OTHERS                     = 8.
Populate zerror return code
  LD_ERROR = SY-SUBRC.
Populate zreceiver return code
  LOOP AT T_RECEIVERS.
    LD_RECEIVER = T_RECEIVERS-RETRN_CODE.
  ENDLOOP.
ENDFORM.                    "send_file_as_email_attachment
*&      Form  FCONVERT_SPOOL_TO_PDF
      text
-->  p1        text
<--  p2        text
FORM FCONVERT_SPOOL_TO_PDF .
  SELECT *
  FROM TSP01
  WHERE RQOWNER EQ SY-UNAME
  ORDER BY RQCRETIME ASCENDING.
  ENDSELECT.
  GD_SPOOL_NR = TSP01-RQIDENT.
  CALL FUNCTION 'CONVERT_ABAPSPOOLJOB_2_PDF'
    EXPORTING
      SRC_SPOOLID              = GD_SPOOL_NR
      NO_DIALOG                = C_NO
      DST_DEVICE               = C_DEVICE
    IMPORTING
      PDF_BYTECOUNT            = GD_BYTECOUNT
    TABLES
      PDF                      = IT_PDF_OUTPUT
    EXCEPTIONS
      ERR_NO_ABAP_SPOOLJOB     = 1
      ERR_NO_SPOOLJOB          = 2
      ERR_NO_PERMISSION        = 3
      ERR_CONV_NOT_POSSIBLE    = 4
      ERR_BAD_DESTDEVICE       = 5
      USER_CANCELLED           = 6
      ERR_SPOOLERROR           = 7
      ERR_TEMSEERROR           = 8
      ERR_BTCJOB_OPEN_FAILED   = 9
      ERR_BTCJOB_SUBMIT_FAILED = 10
      ERR_BTCJOB_CLOSE_FAILED  = 11
      OTHERS                   = 12.
  CHECK SY-SUBRC = 0.
  FREE GD_BUFFER.
Transfer the 132-long strings to 255-long strings
  LOOP AT IT_PDF_OUTPUT.
    TRANSLATE IT_PDF_OUTPUT USING ' ~'.
    CONCATENATE GD_BUFFER IT_PDF_OUTPUT INTO GD_BUFFER.
  ENDLOOP.
  TRANSLATE GD_BUFFER USING '~ '.
  FREE IT_MESS_ATT.
  DO.
    IT_MESS_ATT = GD_BUFFER.
    APPEND IT_MESS_ATT.
    SHIFT GD_BUFFER LEFT BY 255 PLACES.
    IF GD_BUFFER IS INITIAL.
      EXIT.
    ENDIF.
  ENDDO.
*clear:
ENDFORM.                    " FCONVERT_SPOOL_TO_PDF

Hi,
I think problem is in this code :-->
IF SY-SYSID = C_DEV.              
WAIT UP TO 5 SECONDS.
SUBMIT RSCONN01 WITH MODE = 'INT'  " << Here session created internally
WITH OUTPUT = 'X'
AND RETURN.
ENDIF.
ELSE.
PERFORM FCONVERT_SPOOL_TO_PDF.
PERFORM PROCESS_EMAIL.
IF P_DELSPL EQ 'X'.
PERFORM DELETE_SPOOL.
ENDIF.
IF SY-SYSID = C_DEV.
WAIT UP TO 5 SECONDS.
SUBMIT RSCONN01 WITH MODE = 'INT'  " << Here sessions created internally
WITH OUTPUT = 'X'
AND RETURN.
ENDIF.

Similar Messages

  • Alv out put error

    Hi,
    iam getting out put by alv
    but when i caluclate totlal on quntity field iam getting runtime error like this
    plz tell the solution for correct it.
    error is:
    What happened?
        The current application program detected a situation which really
        should not occur. Therefore, a termination with a short dump was
        triggered on purpose by the key word MESSAGE (type X).
      Short text of error message:
      Long text of error message:
      Technical information about the messag
      Message class....... "0K"
      Number.............. 000
      Variable 1.......... " "
      Variable 2.......... " "
      Variable 3.......... " "
      Variable 4.......... " "

    Hi sivaram,
    after you got a solution to your question  you should close the thread and let us know what the solution was.
    Regards,
    Clemens

  • PO E-Mail Out Put Error ( E-mail address incorrect or non-existent )

    Hi Gurus,
    I'M getting the error " E-mail address incorrect or non-existent" when i process the out put type for email of PO.
    I maintained all the settings which are mentioned below ,
    Goto NACE .
    u2022 Select EF and click on OUTPUT TYPES.
    u2022 Then select Output Type NEU and click on processing routines .
    u2022 In that you have to add a new entry - medium 5 .
    u2022 Then you need to assign a program, form routine and form.
    u2022 You can use the standard program i.e. SAPFM06P, FORM routine is always ENTRY_NEU and standard MEDRUCK.
    u2022 Then in PARTNER FUNCTION you need to add a new entry : medium - 5 and function - VN .
    u2022 For subject of the mail goto Mail Title and Texts. In title give PO No. &EKKO-EBELN& .
    u2022 Under General data -> Replacement of text symbols give programm as SAPMM06E and Form Routine as TEXT_SYMBOL_REPLACE .
    u2022 You need to maintain your email id in tcode SU01 and also the vendor's email id.
    u2022 Now while creating a new purchase order , change the medium to External Send .
    u2022 Then goto Communication Method and select CS01 . ALSO make sure that the Cover Page Text has value PO No. &EKKO-EBELN& .
    u2022 Goto tcode ME9F .
    u2022 Execute. 
    Still I'm getting  the same error " E-mail address incorrect or non-existent". could any body help me in this issue?
    Regards,
    Sri.........

    Hi Deepak
    I have gone through the notes which u have mentioned, but it is not helping to my query,
    I had maintained SMTP port in the tcode SCOT.Then I'm getting the message "MAIl request 000000000002 created" when I run tcode ME9F for email out put.But I'm not getting the out put in the email address which I specified in the vendor master record. I can see one error in the transaction code SCOT. should i run transaction SCOT manually every time ?
    Regards,
    Sri...........

  • GR out put error :No messages for initial processing exist

    Hi All
    When Im process the out put for GR using T-Code MB90, the following message appears and I'm able to see the out put "No messages for initial processing exist".I have checked the three processing modes even it is giving the same mesaage.Can any body help  to how to see the GR out put.
    thanks and regards,
    Sri.........

    Hi ,
    I think the necessary condition records might not exist.
    You can maintain the same using MN21.
    Also check whether the necessary customising is done using Transaction NACE and by selecting application ME.
    Regards
    Ramesh Ch

  • Delivery out put error

    hi gurus,
    in our delivery challan output the item is not printed.
    please show me the possible solutions asap.
    because we have to go to golive we shortly.
    thankyou.

    Hello Friend,
    Dont panic these things are common at go live period. Ask your Abaper to debug that output as to why it is not picking up the material number.Best of Luck.

  • On the input :   error message if there is no such id in the database to edit?  and out put comments messed up the whole

    The first page (CoGetEditForm.cfm lets you input the co id
    then it get to the next page for you to edit (CoEditForm.cfm). then
    it lets take action and UPDATEs (CoEditAction.cfm) finally, it goes
    to the colist.cfm to query results and outputs it to html format.
    <td>#comm#</td>
    Question is that:
    1. where and what do I do to have an error message if there
    is no such id in the database to edit?
    2. the out put comments messed up the whole query results
    when I added it to the html out put results. What can I do to clean
    this up and where do I put the code?
    <!-------------------------edit
    page----------------------------->
    <html>
    <head>
    <title>Main Title</title>
    <link rel="stylesheet" href="styles.css">
    </head>
    <body>
    <h1>Edit a Co based on co_ID</h1>
    <table>
    <cfform action="CO_EditForm.cfm" method="POST">
    <tr>
    <td>Co_ID</td>
    <td>
    <cfinput type="Text"
    name="Co_ID"
    message="Please enter the Co_ID"
    validate="integer"
    required="Yes"
    size="22"
    maxlength="20">
    </td>
    </tr>
    <tr>
    <td> </td>
    <td>
    <input type="submit" value="GetCo">
    </td>
    </tr>
    </cfform>
    </table>
    </body>
    </html>
    <!------------------------------------------CO_EditForm.cfm
    page------------------------------------->
    <cfquery name="GetCo"
    datasource="#Request.MainDSN#">
    SELECT
    COName,
    ADD,
    City,
    st,
    zip,
    comm
    FROM
    CO
    WHERE
    Co_ID = #Val(Co_ID)#
    </cfquery>
    <html>
    <head>
    <title>Main Title</title>
    <link rel="stylesheet" href="styles.css">
    </head>
    <body>
    <h1>Edit a CO</h1>
    <table>
    <cfform action="COEditAction.cfm" method="POST">
    <cfoutput>
    <input type="hidden" name="COID" value="#Val(COID)#">
    </cfoutput>
    <tr>
    <td>CO Name</td>
    <td>
    <cfinput type="Text"
    name="COName"
    value="#GetCO.COName#"
    message="Please enter a name for this CO."
    required="Yes"
    size="40"
    maxlength="40">
    </td>
    </tr>
    <tr>
    <td>ADD</td>
    <td>
    <cfinput type="Text"
    name="ADD"
    value="#GetCO.ADD#"
    message="Please enter this new CO's ADD."
    required="Yes"
    size="32"
    maxlength="30">
    </td>
    </tr>
    <tr>
    <td>City</td>
    <td>
    <cfinput type="Text"
    name="City"
    value="#GetCO.City#"
    message="Please enter a city."
    required="Yes"
    size="22"
    maxlength="20">
    </td>
    </tr>
    <tr>
    <td>st</td>
    <td>
    <cfinput type="Text"
    name="st"
    value="#GetCO.st#"
    message="Please enter a st."
    required="Yes"
    size="3"
    maxlength="2">
    </td>
    </tr>
    <tr>
    <td>ZIP Code</td>
    <td>
    <cfinput type="Text"
    name="zip"
    value="#GetCO.zip#"
    message="Please enter a valid ZIP Code."
    validate="zip"
    required="Yes"
    size="11"
    maxlength="10">
    </td>
    </tr>
    <tr>
    <td>comm</td>
    <td>
    <textarea cols="40" rows="5"
    name="comm"><cfoutput>#GetCO.comm#</cfoutput></textarea>
    </td>
    </tr>
    <tr>
    <td> </td>
    <td>
    <input type="submit" value="Update Database">
    </td>
    </tr>
    </cfform>
    </table>
    </body>
    </html>
    <cfquery name="UpdateCO"
    datasource="#Request.MainDSN#">
    UPDATE CO
    SET
    COName = '#Trim(Form.COName)#',
    ADD = '#Trim(Form.ADD)#',
    City = '#Trim(Form.City)#',
    st = '#Trim(Form.st)#',
    zip = '#Trim(Form.zip)#',
    comm =
    <cfif Len(Trim(Form.comm)) GT 0>
    '#Trim(Form.comm)#'
    <cfelse>
    NULL
    </cfif>
    WHERE
    COID = #Val(Form.COID)#
    </cfquery>
    <cflocation url="COList.cfm">
    <cfquery name="GetCo"
    datasource="#Request.MainDSN#">
    SELECT
    coID,
    coName,
    ADD,
    City,
    st,
    zip,
    comm
    FROM
    co
    ORDER BY
    coName ASC
    </cfquery>
    <html>
    <head>
    <title>title getco</title>
    <link rel="stylesheet" href="styles.css">
    </head>
    <body>
    <h1>y List</h1>
    <table>
    <tr>
    <td><b>ID</b></td>
    <td><b>Name</b></td>
    <td><b>ADD</b></td>
    <td><b>City</b></td>
    <td><b>st</b></td>
    <td><b>ZIP Code</b></td>
    <td><b>comm</b></td>
    <td> </td>
    </tr>
    <cfoutput query="GetCompanies">
    <tr bgcolor="<cfif currentrow mod
    2>GHOSTWHITE<cfelse>WHITE</cfif>">
    <td>#coID#</td>
    <td>#coName#</td>
    <td>#ADD#</td>
    <td>#City#</td>
    <td>#st#</td>
    <td>#zip#</td>
    <td>#comm#</td>
    <td>
    <a
    href="EmployeeList.cfm?coID=#coID#">Employees</a>
    <a href="coAddForm.cfm">Add</a>
    <a href="coEditForm.cfm?coID=#coID#">Edit</a>
    <a
    href="coDeleteForm.cfm?coID=#coID#">Delete</a>
    </td>
    </tr>
    </cfoutput>
    </table>
    </body>
    </html>

    After your SQL SELECT on CO_EditForm.cfm, you need a
    <CFIF> that checks to see if any records were retrieved. See
    below.

  • Out put determination error in billing

    Hi
    In my current  project I have to do printing of mass billing documents at once
    For this i configured output condition type ZD00 and access sequeunce ZBNG
    I have defined procedure Z10000 and assigned condition type to it  and done all necessary configuration
    When i create billing document and take print preview the values come correctly .but when i go to the t code vf02 and see the header --output the out put is determined but shows color RED indicating error
    My abaper has debuuged the programm and found that two tables T682V and T683S should contain the entries of condition type ZD00
    Table T683S containes the entries but in table T682V the enrtires of condition type ZD00 are not found
    What i want to know is that is there a config setting to pass entries into this table so that i can do the same
    Thanks and Regards
    Suneel Srinivasan

    Hi,
    Pleae compare your configuration with below article. You should be able to find the missing configuration. Output configuration is done under the transaction NACE. If you configure it correctly and then maintain output condition records correctly, system should issue them.
    [Output config|http://learnsaptips.blogspot.com/2010/08/output-determination-in-sap.html]
    Please let us know if you can't find what is missing!
    Best regards,
    Rahal

  • Printing all error messages in the out put report

    Hi all,
    I have MATNR and WERKS data in final internal table now my requirement is ineed to print all the error messages for all the materials (where sy-subrc ne 0) in the out put report. how can i do it for multiple error records will anybody tell me with coding
    The Requirement is like bellow:
    Take material number(s) (MARC-MATNR) from selection screen then check to see if any plants have that material setup as QM active (MARC-QMATV).  If no, then issue message on report.
    Thanks,

    Hi Mythili,
    Hope the attached code helps you...
    TABLES marc.
    TYPE-POOLS: slis.
    TYPES : BEGIN OF g_ty_msg,
            type LIKE sy-msgty,
            msg(120),
           END OF g_ty_msg.
    TYPES: BEGIN OF g_ty_marc,
            matnr TYPE matnr,
            werks TYPE werks_d,
            qmatv TYPE qmatv,
          END OF g_ty_marc.
    DATA: g_t_msg TYPE TABLE OF g_ty_msg,
          g_r_msg TYPE g_ty_msg.
    DATA: g_t_marc TYPE TABLE OF g_ty_marc.
    FIELD-SYMBOLS <fs_marc> TYPE g_ty_marc.
    SELECT-OPTIONS: s_matnr FOR marc-matnr,
                    s_werks FOR marc-werks.
    START-OF-SELECTION.
      SELECT matnr werks qmatv FROM marc
        INTO TABLE g_t_marc
        WHERE matnr IN s_matnr AND
              werks IN s_werks.
      IF g_t_marc IS NOT INITIAL.
        LOOP AT g_t_marc ASSIGNING <fs_marc>.
          IF <fs_marc>-qmatv IS INITIAL.
            g_r_msg-type = 'E'.
            CONCATENATE <fs_marc>-matnr <fs_marc>-werks
              INTO g_r_msg-msg SEPARATED BY space.
            APPEND g_r_msg TO g_t_msg.
            CLEAR g_r_msg.
          ENDIF.
        ENDLOOP.
      ENDIF.
    END-OF-SELECTION.
      PERFORM display_log.
    *&      Form  display_log
          To display error log as an ALV Popup
    FORM display_log .
      CONSTANTS: l_c_type(4)    TYPE c VALUE 'TYPE',
                 l_c_msg(3)     TYPE c VALUE 'MSG'.
      DATA :  l_t_fieldcat TYPE TABLE OF slis_fieldcat_alv,
              l_r_fieldcat TYPE slis_fieldcat_alv.
      DATA :  l_f_line TYPE i.
      CLEAR l_r_fieldcat.
      l_f_line = l_f_line + 1.
      l_r_fieldcat-col_pos    = l_f_line.
      l_r_fieldcat-fieldname  = l_c_type.
      l_r_fieldcat-seltext_m  = 'Type'.
      APPEND l_r_fieldcat TO l_t_fieldcat.
      CLEAR l_r_fieldcat.
      l_f_line = l_f_line + 1.
      l_r_fieldcat-col_pos = l_f_line.
      l_r_fieldcat-fieldname = l_c_msg.
      l_r_fieldcat-seltext_m = 'Message'.
      l_r_fieldcat-outputlen = 120.
      APPEND l_r_fieldcat TO l_t_fieldcat.
    To display the message log as a Popup in the form of ALV List
      CALL FUNCTION 'REUSE_ALV_POPUP_TO_SELECT'
        EXPORTING
          i_title       = 'Message Log'
          i_tabname     = 'G_TY_MSG'
          it_fieldcat   = l_t_fieldcat[]
        TABLES
          t_outtab      = g_t_msg
        EXCEPTIONS
          program_error = 1
          OTHERS        = 2.
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ENDIF.
    ENDFORM.                    " display_log
    Best Regards,
    Suresh

  • Out put Determination Error

    Hi All,
    i have created a new out put type and added this output type to an existing output determination procedure.
    I have assigned this new output type to partner funcitons.
    Created a condition record for the out put type
    But when i create the sales order and see the output, the output type is not automatically copied to sales order.
    I am not able to view the print preview.
    The determination analy

    Hi All, Thank you so much for the replys.
    I have done the out put config setting correctly.
    The output determination analysys says " Printer not configured for the output type"
    Is the printer configuration is the reason for not getting the output type copied to sales order?
    Could anyone tell me what is the Tcode to setup printer parameters and what values need to be maintained there
    Thanks in advance,
    Srini

  • XML PUBLISHER report in Excel out put problem

    Hi Experts,
    I have developed one XML report which output type is EXCEL in Oracle Application.
    I am getting some -ve value in the report so I need to do the trailing sign
    Menace for example I got a value -8645 I need to display the value like (8645).
    This functionality is working in PDF output but in EXCEL out put it is not working.
    Could any body please help me on this..
    Its Urgent .
    Thanks in Advance.

    Check this metalink notes, did you got any error..?
    Note: 364547.1 - Troubleshooting Oracle XML Publisher For The Oracle E-Business Suite
    https://metalink.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=364547.1
    Note: 359875.1 - Cannot View Xml Publisher Report Output In Excel Format
    Note: 358296.1 - How To Produce Requests In Formats Of HTML, RTF, and Excel From XML Publisher
    Note: 850685.1 - Wrong Output Format In Xml Publisher Output
    Note: 727031.1 - XML Publisher Requests Always Get Defaulted to Output Format as PDF Whatever the Template Type is Set To
    Note: 337343.1 - Unable to View Excel Output File Created by XML Publisher
    Note: 401328.1 - Default Layout Format for XML Publisher Concurrent Request Is Always PDF
    Re: XML Publisher Server on EBS 11.5.10.2

  • Delivery out put issue

    hi,
    i am not able to get the print preview for delivery output, i have checked delivery output has got determined, when i goto vl02n, and issue out put then i am able to get the delivery output type, when i select the output type and click on the print preview i get the error "output could not be issued" errormessage no. vl086.
    please suggest

    Hi,
    1) Kindly check what output type is assisgned to the Delivery Type at OVLK.
    2) Then goto Tcode-> NACE.
    Select V2-> 'Shipping' and click on Condition Record.
    Then select the approprieate Access sequence and check whether condition record is maintained or not.
    3) If condition record does not exit create , if created then select the approprieate method and Select the condition record and click on the communication button. Here Output Device, Print immediately should be checked.
    Thank You,
    RB

  • Special charactors found in out put file of .xml file in file adapter

    Hi ,
    Dear all,
    I am working on Sender File adapter picking files from the multiple Directories which are specified in a single CC and these files are placed in the different receiver directories in different CC's metained paths of the receivers
    The Souce is XML.
    When I use  the receiver format as .csv,.txt it the out put is as excepted,when i give the receiver format as .XML the output file contents:PK   (An invalid character was found in text content. Error processing resource 'file:).
    Pl let me know how to tackle thsi situation.
    Thanks,
    Srini

    Hi
    Also try with the following UDF.
    public class XmlUtil {
        char[] specialCharacters = { '&', '<'>', '\'' };
        String[] replacementStrings = { "&", "<">", "&apos;" };
        public static String sanitizeText( String text ) {
            StringBuffer buffer = new StringBuffer( text );
            for( int i = 0; i < buffer.length(); i++ ) {
                for( int k = 0; i < specialCharacters.length; k++ ) {
                    if( buffer.charAt(i) == specialCharacters[k] ) ) {
                         buffer.replace( i, i + 1, replacementString[k] );
                         i += replaceString[k].length;
                    } else if( (int)buffer.charAt(i) > 128 ) {
                         String replacement = "&#" + (int)buffer.charAt(i) + ";";
                         buffer.replace( i, i + 1, replacement );
                         i += replacement.length();
            return buffer.toString();
    Regards
    Abhishek Mahajan

  • ALV Report In Background.. Generating same out put using ABAP Extracts

    Hi
        We are running ALV reports and generating out put in background using Extracts. We are having a discussion that SAP doesn’t recommend to execute ALV reports using batch and generate report output , as it heavily load for spool ... we are coming across some problem when I analyze Sm37 ... I found an error " ABAP framework unable to initialize " .
    I want an input/suggestion what you guys think about it?
    Thanks in Advanced...
    Bye

    Nope... We’re using some batch id which use to run background job, as I am also in SAP Security, I just verify it has all the security to run the report . As this report is running fine if we ran it other then batch id ... as before it was running fine .
    Thanks
    Message was edited by: Saquib Khan

  • How to generate idoc  PODRCH02 using out put type

    Hi All,
    I need to generate outbound idoc PORDCH02 and message type PORDCH using out put types (messages).But i unable to generated this idoc using message type. System is giving error as  *No recipient found for message type PORDCH in the ALE model*
    To do this , i have done the following steps.
    1. In BD64 i have configure the business object BUS2012, using add bapi. ( In cust.distn model it doesn't allowing the message type. so i have given BAPI )
    2. In partner profile (WE20), for sending logical sytems
    i have configure the message type in outbound parametes.
    3. In NACE for out put type NEU  i have given medium as Distribution (ALE),  Partner function as LS     
    Could you please help me out , what are the necessary steps i need to take care and what are the steps i missed out.
    Thanks and regards
    Praveen

    In distribution model, you have to configure both the sending system and receiving system. The Tcode of Distribution model is BD64.

  • Out put file is not genrated when calling xml reports from OAF page

    Dear all
    i am calling xml reports from OAF page
    the out put file is not generated
    i am writing this code
    public int tradingrequest(String quoid, String costoder,int orgid)
    try
    OADBTransaction tx = (OADBTransaction)getOADBTransaction();
    java.sql.Connection pConncection = tx.getJdbcConnection();
    ConcurrentRequest cr = new ConcurrentRequest(pConncection);
    String applnName =
    "XXCRM"; //Application that contains the concurrent program
    String cpName = "XXCRM_COSTSHEET"; //Concurrent program short name
    String cpDesc =
    "Trading Costsheet Report XXCRM"; // concurrent Program description
    Number orgid1=new Number(orgid);
    // Pass the Arguments using vector
    Vector cpArgs = new Vector();
    cpArgs.addElement(quoid);
    cpArgs.addElement(costoder);
    cpArgs.addElement(orgid1.toString());
    // Calling the Concurrent Program
    int requestId =
    cr.submitRequest(applnName, cpName, cpDesc, null, false, cpArgs);
    tx.commit();
    System.out.println("Request ID is " + requestId);
    return requestId;
    } catch (RequestSubmissionException e)
    OAException oe = new OAException(e.getMessage());
    oe.setApplicationModule(this);
    throw oe;
    in controller i am writing this code
    OAMessageStyledTextBean y =
    (OAMessageStyledTextBean)webBean.findChildRecursive("quotationid");
    OAFormValueBean z =
    (OAFormValueBean)webBean.findChildRecursive("costorder");
    String quoid = y.getValue(pageContext).toString();
    String costorder = z.getValue(pageContext).toString();
    System.out.println("The quotation id and costing order are....." + quoid +
    " " + costorder);
    /*if click on run report button to run the report*/
    if ("Viewreport".equals(pageContext.getParameter(EVENT_PARAM)))
    if (tsflag.equals("Y"))
    int requestid = am.servicerequest(quoid, costorder, orgid);
    String url =
    "OA.jsp?akRegionCode=FNDCPREQUESTVIEWPAGE&akRegionApplicationId=0&retainAM=Y&addBreadCrumb=Y&REQUESTID=" +
    requestid;
    pageContext.setForwardURL(url, null,
    OAWebBeanConstants.KEEP_MENU_CONTEXT, null,
    null, true,
    OAWebBeanConstants.ADD_BREAD_CRUMB_YES,
    OAWebBeanConstants.IGNORE_MESSAGES);
    when i call the report from oaf page the request id is coming
    when i click on view output i am getting this message
    Error
    The concurrent request 7335031 did not create an output file.
    WHEN I GOTO FIND REQUESTS PAGE QUERY THIS REQUEST ID I AM GETTING THE OUTPUT IN XM FILE
    Regards
    Sreekanth

    java.io.FileNotFoundException: \..\..\..\xdoAqdFFZfuuJ051010_0628487460.fo (The system cannot find the path specified)
    MY CO code
    if("GenerateReport".equals(event))
    // Get the HttpServletResponse object from the PageContext. The report output is written to HttpServletResponse.
    DataObject sessionDictionary = (DataObject)pageContext.getNamedDataObject("_SessionParameters");
    HttpServletResponse response = (HttpServletResponse)sessionDictionary.selectValue(null,"HttpServletResponse");
    try {
    // Hashtable hashtable = new Hashtable(1);
    // hashtable.put("TruckBookingRefNum",trucknum);
    // System.out.println("test"+trucknum);
    ServletOutputStream os = response.getOutputStream();
    // Set the Output Report File Name and Content Type
    String contentDisposition = "attachment;filename=LF Cargo Summary Report.htm";
    response.setHeader("Content-Disposition",contentDisposition);
    response.setContentType("application/HTML");
    // Get the Data XML File as the XMLNode
    XMLNode xmlNode = (XMLNode) am.invokeMethod("getTestDataXML");
    ByteArrayOutputStream outputStream = new ByteArrayOutputStream();
    xmlNode.print(outputStream);
    ByteArrayInputStream inputStream = new ByteArrayInputStream(outputStream.toByteArray());
    ByteArrayOutputStream pdfFile = new ByteArrayOutputStream();
    System.out.println(" ByteArrayInputStream.ByteArrayOutputStream"+pdfFile+inputStream);
    //Generate the PDF Report.
    TemplateHelper.processTemplate(
    ((OADBTransactionImpl)pageContext.getApplicationModule(webBean).getOADBTransaction()).getAppsContext(),
    "LFCUST",
    "XXLFCARSUM_TARGET",
    "English",//((OADBTransactionImpl)pageContext.getApplicationModule(webBean).getOADBTransaction()).getUserLocale().getLanguage(),
    "US",//((OADBTransactionImpl)pageContext.getApplicationModule(webBean).getOADBTransaction()).getUserLocale().getCountry(),
    inputStream,
    TemplateHelper.OUTPUT_TYPE_HTML,
    null,
    pdfFile);
    // hashtable);
    System.out.println(" TemplateHelper");
    // Write the PDF Report to the HttpServletResponse object and flush.
    byte[] b = pdfFile.toByteArray();
    System.out.println(" byte"+b);
    response.setContentLength(b.length);
    os.write(b, 0, b.length);
    os.flush();
    os.close();
    pdfFile.flush();
    pdfFile.close();
    catch(Exception e)
    System.out.println(" inside catch");
    response.setContentType("text/html");
    throw new OAException(e.getMessage(), OAException.ERROR);
    pageContext.setDocumentRendered(true);
    Edited by: user9367919 on May 13, 2010 10:31 AM

Maybe you are looking for

  • HT4463 How do I get back to the same page I was on?

    When I have finished reviewing an app, if I click the back arrow in the top left corner it takes me back to the first page of the category. Not very user friendly when there are dozens of pages to click through to get back to where you were. How do I

  • Acrobat Reader X slow to open

    Acrobat Reader X (10.1.0) is slow to open on some computers. I've read that removing the 'Protected Mode' seeems to correct the problem. Is that right? Is there other setups we should change? Thanks

  • Material Price on SO should be based on PO price

    Hi All I working with User on a requirement. We send Outbound PO to system and that triggers SO in receiving system. But the Material price on SO should be based on PO price. Please suggest. Regards Edited by: Swapnika Gudujada on Feb 15, 2011 6:26 A

  • Particle detection with grid background

    I am attempting to detect cells in an image from a microscope, but the problem is that a grid background exists which prevents the typical thresholding method to work. I have tried using a low pass filter to remove the grid pattern, but in order to f

  • Installing Portal Server 7.1 on Windows XP

    I installed Portal Server 7.1 for Windows, via the Sun Java Application Platform Suite Installer. The installer was super clean and very easy--practically idiot-proof. It is substantially easier to install than the SPARC version. However, during inst