How to print multiple PDF attachments from report

Hello experts,
I have developed an ALV report that is having some PDF attachments and I have push button(Print all) as shown in below image.
When I click on print all button all the pdf attachments should be send to printer.
I did check in the SCN but I found some posts to print single pdf from after opening the pdf and some posts to view a pdf file which is saved on desktop but in my requirement I have multiple pdf attachments and I have to send all the attachments to printer with print all button click without opening the attachmens.
Can you please help me to resolve this issue.Thanks in advance.
Thanks & Regards
Suman

Hi,
Your Requirement is bit complex,
i hope we can achieve the solution if follows bellow links and we use application server for temporary storage.
Print Adobe Document from any URL link in SAP ABAP.
Hope this will help you.

Similar Messages

  • Multiple pdf attachments from server folder using SO_DOCUMENT_SEND_API1

    Dears,
    I am trying to build a program able to send an email with multiple pdf attachments.
    The files are stored in a folder in SAP server.
    I am able to generate a pdf file from a spool and sucessfully attach it to the email using:
    CALL FUNCTION 'CONVERT_OTF_2_PDF'
          IMPORTING
            bin_filesize           = v_bin_filesize
          TABLES
            otf                    = job_output_info-otfdata
            doctab_archive         = it_docs
            lines                  = it_lines
          EXCEPTIONS
            err_conv_not_possible  = 1
            err_otf_mc_noendmarker = 2
            OTHERS                 = 3.
        IF sy-subrc = 0.
          LOOP AT it_lines.
            TRANSLATE it_lines USING ' ~'.
            CONCATENATE gd_buffer it_lines INTO gd_buffer.
          ENDLOOP.
          TRANSLATE gd_buffer USING '~ '.
          DO.
            it_mess_att_aux = gd_buffer.
            APPEND it_mess_att_aux.
            SHIFT gd_buffer LEFT BY 255 PLACES.
            IF gd_buffer IS INITIAL.
              EXIT.
            ENDIF.
          ENDDO.
        ENDIF.
    Internal table it_mess_att_aux is the parameter contents_bin of FM SO_DOCUMENT_SEND_API1.
    I have now 2 files on a server folder which I would like to include as well.
    I am reading the content of the pdf files in following way:
    DATA:   gd_buffer                 TYPE string,
          OPEN DATASET lv_fileserver FOR INPUT IN BINARY MODE.
          IF sy-subrc <> 0.
            MESSAGE e257(zmsgsd) WITH lv_fileserver.
          ELSE.
            CLEAR: it_mess_att_aux[], gd_buffer.
            DO.
              READ DATASET lv_fileserver INTO gd_buffer.
              IF sy-subrc <> 0.
                EXIT.
              ENDIF.
              APPEND gd_buffer TO it_mess_att_aux.
            ENDDO.
            APPEND LINES OF it_mess_att_aux TO it_mess_att.
    I do not understand the purpose of the statement:
            TRANSLATE it_lines USING ' ~'.
    in this context. Could anyone explain it?
    All the files are attached to email with the desired name but corrupted and with the wrong size.
    Can anyone help me build the logic to attach a pdf file from server in a email?
    Thank you in advance,
    Kind Regards,
    João Cabrita

    hi , try this ,it is working fine  .
      DATA: i_objbin LIKE solisti1 OCCURS 0 WITH HEADER LINE,
              i_objpack LIKE sopcklsti1 OCCURS 0 WITH HEADER LINE,
              i_reclist LIKE somlreci1 OCCURS 0 WITH HEADER LINE,
    *          wa_doc_chng LIKE sodocchgi1,
              i_objtxt LIKE solisti1 OCCURS 0 WITH HEADER LINE,
    *         i_objpack LIKE sopcklsti1 OCCURS 0 WITH HEADER LINE,
           i_objhead LIKE solisti1 OCCURS 0 WITH HEADER LINE,
          i_tline TYPE TABLE OF tline WITH HEADER LINE,
          i_record LIKE solisti1 OCCURS 0 WITH HEADER LINE,
          wa_doc_chng LIKE sodocchgi1,
          v_lines_txt TYPE i,
           l_lines TYPE I VALUE '20'.
      CALL FUNCTION 'CONVERT_OTF'
        EXPORTING
          format        = 'PDF'
          max_linewidth = 132
        IMPORTING
          bin_filesize  = bin_filesize
        TABLES
          otf           = int_tab_otf_final
          lines         = int_pdf_tab.
      IF sy-subrc <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    *****************soc ranjan***************************
    *  IF full_path IS INITIAL.
    *    CALL METHOD cl_gui_frontend_services=>file_save_dialog
    *      EXPORTING
    **    WINDOW_TITLE         =
    **           DEFAULT_EXTENSION    = 'PDF'
    **    DEFAULT_FILE_NAME    =
    *           file_filter          = 'Portable Document Format (.pdf)' " for restricting saving file only as pdf
    *      CHANGING
    *        filename             = file_name
    *        path                 = file_path
    *        fullpath             = full_path
    *    IF sy-subrc <> 0.
    ** MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    **            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    *    ENDIF.
    *  ENDIF.
    ******************eoc ranjan*****************
    *break-point.
      CONCATENATE full_path git_select_option-pernr INTO path SEPARATED BY '_'.
      CONCATENATE path 'PDF' INTO path SEPARATED BY '.'.
    **  **************************for downloading*********************************
    *  CALL FUNCTION 'GUI_DOWNLOAD'
    *    EXPORTING
    *      bin_filesize = bin_filesize
    *      filename     = path
    *      filetype     = 'BIN'
    *    IMPORTING
    *      filelength   = file_size
    *    TABLES
    *      data_tab     = int_pdf_tab.
    *  IF sy-subrc <> 0.
    ** MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    **         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    *  ENDIF.
      CLEAR : lop , el , sl , cl .
    *  ******************addeddd later  by ranjan  21.04.2011
    DATA : desc TYPE char40 ,
          desc1 TYPE char100 .
      CALL FUNCTION 'QCE1_CONVERT'
    TABLES
    t_source_tab = int_pdf_tab
    t_target_tab = i_record
    EXCEPTIONS
    convert_not_possible = 1
    OTHERS = 2.
    IF sy-subrc <> 0.
    WRITE : / 'Error in conversion of pdf lines'(015).
    ENDIF.
    APPEND LINES OF i_record TO i_objbin.
    *Creation of the entry for the compressed attachment
    DESCRIBE TABLE i_objbin LINES bin_filesize.
    i_objtxt = 'Hi'.
    APPEND i_objtxt.
    i_objtxt = '                                     '.
    APPEND i_objtxt.
    i_objtxt = 'Pls  find  the attached  salary slip ' .
    APPEND i_objtxt.
    i_objtxt = '  '.
    APPEND i_objtxt.
    i_objtxt = '  '.
    APPEND i_objtxt.
    i_objtxt = '  '.
    APPEND i_objtxt.
    i_objtxt = '  '.
    APPEND i_objtxt.
    i_objtxt = '  '.
    APPEND i_objtxt.
    i_objtxt = '         '.
    APPEND i_objtxt.
    i_objtxt = '  '.
    APPEND i_objtxt.
    i_objtxt = '  '.
    APPEND i_objtxt.
    i_objtxt = '        '.
    APPEND i_objtxt.
    i_objtxt = '  '.
    APPEND i_objtxt.
    i_objtxt = '         '.
    APPEND i_objtxt.
    i_objtxt = '  '.
    APPEND i_objtxt.
    i_objtxt = '  '.
    APPEND i_objtxt.
    i_objtxt = '         '.
    APPEND i_objtxt.
    i_objtxt = '  '.
    APPEND i_objtxt.
    i_objtxt = 'Regards:  '.
    APPEND i_objtxt.
    i_objtxt = 'Corporate HR  '.
    APPEND i_objtxt.
    DESCRIBE TABLE i_objtxt LINES L_LINES.
    READ TABLE i_objtxt INDEX L_LINES.
    wa_doc_chng-doc_size = ( L_LINES - 1 ) * 255 + STRLEN( i_objtxt ).
    *Creating the entry for the compressed document
    CLEAR i_objpack-transf_bin.
    i_objpack-head_start = 1.
    i_objpack-head_num = 0.
    i_objpack-body_start = 1.
    i_objpack-body_num = L_LINES.
    i_objpack-doc_type = 'RAW'.
    APPEND i_objpack.
    ***CLEAR:  i_objpack .
    ***i_objpack-transf_bin = ' '.
    **i_objpack-head_start = 1.
    **i_objpack-head_num = 0.
    **i_objpack-body_start = 1.
    **i_objpack-body_num = L_LINES.
    **i_objpack-doc_type = 'TXT'.
    **i_objpack-obj_descr = desc1 .
    **APPEND i_objpack.
    *CLEAR: i_objhead .
    *i_objhead = DESC.
    *APPEND i_objhead.
    *break-point .
    i_objpack-transf_bin = 'X'.
    i_objpack-head_start = 1.
    i_objpack-head_num = 1.
    i_objpack-body_start = 1.
    i_objpack-body_num = bin_filesize.
    i_objpack-obj_name = 'Employee Payslip'.
    i_objpack-obj_descr = 'Employee Payslip'.
    i_objpack-doc_size = bin_filesize  * 255 .
    i_objpack-doc_type = 'PDF'.
    APPEND i_objpack.
    CONCATENATE 'Salary Slip of Month' p_month INTO desc SEPARATED BY ' ' .
    *DESCRIBE TABLE i_objtxt LINES v_lines_txt.
    *READ TABLE i_objtxt INDEX v_lines_txt.
    ****wa_doc_chng-doc_size = ( v_lines_txt - 1 ) * 375 + STRLEN( i_objtxt ).
    wa_doc_chng-obj_name = 'Payslip'.
    wa_doc_chng-expiry_dat = sy-datum + 10.
    wa_doc_chng-obj_descr = desc.
    wa_doc_chng-sensitivty = 'F'.
    wa_doc_chng-doc_size = v_lines_txt * 255.
    CLEAR i_objpack.
    DATA: l_usrid_long TYPE pa0105-usrid_long.
    DATA : emessage(70) TYPE c.
    CLEAR : l_usrid_long.
    SELECT SINGLE usrid_long
    FROM pa0105
    INTO l_usrid_long
    WHERE pernr = git_pa0001-pernr
    AND subty = '0010'.
    *break-point.
    IF sy-subrc EQ 0.
    i_reclist-receiver = l_usrid_long.                     
    i_reclist-rec_type = 'U'.
    i_reclist-com_type = 'INT'.
    APPEND i_reclist.
    ELSE.
    WRITE:/ 'No email id is maintained for this personnel number' , git_pa0001-pernr.
    ENDIF.
    IF NOT i_reclist[] IS INITIAL.
    ***************************************for senders id *************************************
    CALL FUNCTION 'SO_DOCUMENT_SEND_API1'
      EXPORTING
        document_data                    = wa_doc_chng
      put_in_outbox = 'X'
       sender_address                   = 'xys'
       sender_address_type              = 'SMTP'
       commit_work                      = 'X'
    * IMPORTING
    *   SENT_TO_ALL                      =
    *   NEW_OBJECT_ID                    =
    *   SENDER_ID                        =
      TABLES
    packing_list = i_objpack
    object_header = i_objhead
    contents_bin = i_objbin
    contents_txt = i_objtxt
    receivers = i_reclist
    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.          .
    IF sy-subrc <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.

  • How to Print  a PDF file from within a ABAP ( from gui input)

    Hi champions,
    This is Client requirement:
    "We need to print a PDF file from within a ABAP"
    We first need to test whether it is even feasible, and then if it 
    is, then write a small test ABAP which can accept a PDF file
    name as input (from GUI) and then print it to a SAP print
    device (printer).”
    Please Can any body help me on this.......
    It's urgent
    Thanks
    Basu

    Check following blog for PDF output from SAP
    /people/thomas.jung3/blog/2005/04/28/setting-up-an-adobe-writer-for-abap-output
    anya

  • How to print a pdf file from Labview

    Hi,
    Does anyone know how to print a pdf file form Labview. I need to be able to point on the pdf file and to print it.
    Activex examples doesnt seem to be working it always displays an error, on every PC that I tryed to run it.
    {"code 3005" ,,,"Automation Open: Object specified is not creatable in Display PDF in Dialog.vi"}.
    Thank you for your help.
    Regards,
    Jenia.

    You can use the "System Exec.vi". The command line should have the following structure:
    "<Path to AcroRd32.exe>" /t "<Path to document>" "Printer name"
    For example"
    "C:\Program Files\Adobe\Acrobat 5.0\Reader\AcroRd32.exe" /t "C:\myreport.pdf" "Tektronix Phaser 300i"
    Regards;
    Enrique
    www.vartortech.com

  • How to print a PDF document from Labview?

    I am looking to create a paper copy of a PDF document.  Note: I do NOT want to create a PDF document.
    In other words I want to print a PDF document from Lab View or Visual Basic or C#.  The application is used in a production environment so I want a clean solution.
    The requirements are:
    1) Be able to specify the output printer.
    2) Set the quantity to print.
    3) Specify the file to print.
    4) Function returns when printing is complete
    5) Silent operation, that means no popup boxes.
    Any help is appreciated.

    http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/prnmngr.mspx?mfr=true
    http://forums.ni.com/ni/board/message?board.id=170&message.id=183895&requireLogin=False
    you might be able to use system exec to print files.

  • How to Stop Large PDF attachments from displaying?

    Using Leopard and large PDF attachments (9mb) slow Mail down to a crawl. Is there a way to stop attachments from automatically displaying in Mail. It can be all atachments, it does not have to be just PDF or a certain size.
    Dan

    Hi Mulder,
    I think it must be noted that Plain or Rich Text has no bearing on Mail's ability to View in Place. Nor does View in Place have any bearing on each attachment being a true attachment. Whether it is viewed Inline by the recipient will depend entirely on the recipients email client, and not how you send.
    View in Place must not be confused with embedding images into text. The frequent discussion in these forums, and what you refer to, about whether to use Plain Text or RTF is relevant to some recipient email programs seeing inline attachments as embedded images due to the presence of the HTML that results from RTF when multiple fonts and attachments are present. The fact that the person composing sees the attachments with View in Place has no bearing on this issue involving HTML that results from RTF.
    Choosing the View as Icon while you Compose has no bearing on how the recipient's email application displays it.
    With those email clients where you can select to not view attachments inline, those you find viewing in place as you compose will in fact be seen as attached files in Icon form.
    At my request, I was sent a test message with a JPEG prepared using Iconiser -- Mail still displayed the JPEG in the message with View in Place when received. However, an examination in Raw Source form showed the header to the attachment did not have the disposition as "Inline" as it normally would -- this would aid with some recipients, such as those using Lotus Notes, where the attempt to adhere to the inline quality causes problems. But Mail, and some other email clients, can still display the message with attached images with View in Place or Inline View. The use of Iconiser will not guarantee to change that.
    As you have pointed out, zipping will prevent any form of View in Place from working.
    All the best,
    Ernie
    Message was edited by: Ernie Stamper

  • How to exreact multiple pdf files from a zip files from application server to presentation server

    Hello exprts,
    I am passing one pdf file and one text file to zip file in apllication server through my custom program and then downloading it using standard function module to my desktop. its working fine. Then I added  another pdf file to my zip file. But only single pdf file is getting download . So can you please help me regardiong this issue? 

    Dear Experts ,
    I finded out the way to extrcat pdf files in presentation server. But now my problem is that I am not able to add multiple pdf files in a zip file. When I am adding new pdf file then older one is not coming in read data set. So please kindly tell me how can I add multiple pdf file in my zip file and again I can get all the pdf files from here.

  • Is it possible to send multiple PDF attachments from an iPad?

    When sending an email from my iPad, I am unable to send multiple attachments, just one file at a time.
    Is there any way to send two PDF files in one email?
    Thanks,
    Melissa.

    I don't need to send it to multiple contacts, I need to send multiple PDF files in an email from my iPad.
    Thanks for the assistance though.
    Regards,
    Melissa.

  • How to create multiple pdf files from multiple batch processing

    I have several file folders of jpeg images that I need to convert to separate multi-page pdf files. To give a visual explanation:
    Folder 1 (contains 100 jpeg image files) converted to File 1 pdf (100 pages; 1 file)
    Folder 2 (contains 100 jpeg image files) converted to File 2 pdf (100 pages; 1 file)
    and so on.
    I know I can convert each folder's content as a batch process, but I can only figure out how to do so one folder at a time. Is it at all possible to convert multiple folders (containing jpegs) to multiple pdf files? Put differently, does anyone know how to process a batch of folders into multiple (corresponding) pdf files?
    Many thanks.

    There are two approaches to do this:
    - First convert all JPG files to PDF files using a "blank" batch process. Then combine all PDF files in the same folder using another batch process and a folder-level script (to do the actual combining). I have developed this tool in the past and it's available here:
    http://try67.blogspot.com/2010/10/acrobat-batch-combine-all-files-in.html
    - The othe option is to do everything in a single process, but that requires an application outside of Acrobat, which I'm currently developing.
    If you're interested in any of these tools, feel free to contact me personally.

  • How to print a pdf file from reader?

    We have Reader X1 and cannot print a pdf file. Although it says 'print', it only allows us to save the file

    Go to the Printer's properties and make sure that the "Print to File" box is not ticked.

  • Printing multiple PDF's from a website

    I am always needing to email  up to 3 to 4 pdf files from our website to a client and am looking for the best way to do so without having to either re-download them all and attach them or send them all in seperate emails. Any Suggestions ?

    Using Acrobat, yes.

  • How to print a PDF file from Swing(JFC/swing)

    Hi,
    I am able to dislay a PDF file in Swing but how can I print it from there. I want to do it without using Acrobat reader.

    You can use the "System Exec.vi". The command line should have the following structure:
    "<Path to AcroRd32.exe>" /t "<Path to document>" "Printer name"
    For example"
    "C:\Program Files\Adobe\Acrobat 5.0\Reader\AcroRd32.exe" /t "C:\myreport.pdf" "Tektronix Phaser 300i"
    Regards;
    Enrique
    www.vartortech.com

  • How can I print PDF attachments from ABAP report in transaction ME23N?

    Hi,
    Users attach PDF files using "services for objects" in transaction ME23N.
    How can I print the PDF attachments from ABAP report ?
    Thanks in advance,,

    Hi,
      check this link,this might help you to solve your problem
    /people/thomas.jung3/blog/2005/04/28/setting-up-an-adobe-writer-for-abap-output
    Regards
    Kiran Sure

  • How do I print a pdf file from windows 8?

    I can't find a command to print a pdf file. I'm working with windows 8. can anybody tell me how do I find that command?

    Please see FAQ: How to print a PDF file from Adobe Reader Touch.
    Starting from version 1.1, Adobe Reader Touch supports printing.
    If you do not see the Print button in the toolbar, you have an older version of Adobe Reader Touch. Please download and install the latest version of Adobe Reader Touch via the Windows Store.

  • Adobe reader X prints email PDF attachments as english then oriental

    Using Windows XP, IE 8, Adobe Reader X and HP Laserjet 4000 printer.
    Sometimes when I print email PDF attachments from Office Outlook 2003, the attachments start printing in English and then subsequent pages turn into an oriental language (not sure which one). If I view the attachment prior to printing all the pages are clearly in English. Other times if I print the item and it is okay (in English), if I reprint it, it may start in English and then goes to the other language.
    I have not incurred anything like this in any other printing program that I use such as Word or Excel.
    I have no idea why this is happenning. Any ideas what causes this and if so how to correct this?

    Solved it!
    1-go to "edit", select Preferences.
    2-select from the left pane: Security (enhanced)
    3-click on "add folder path" button just below the big white box
    4-pick a folder of your choice and click "ok". (your selected folder path will appear in that white box above the "add folder path" button in step 3)
    5-if you want to add additional folders, just repeat steps 3 & 4
    6-once you are done, click "ok" on the preferences screen and click "ok" again to accept the changes.
    Yes, it seems illogical, but it worked.
    I tested by closing the Reader (X), then surfed the web and did what Neher5 was explaining he/she wanted to do just after opening a pdf from a website and lo-and-behold,  it worked!. No more "save to temp folder" issues.
    Hope this helps.

Maybe you are looking for