How To Batch Print PDF Files

Hello Friends.
I am using Apex 4.1 on Windows 7. My database is Oracle EE 10.2.0.5 on Solaris and OAS as the app server (and so, am using mod_plsql).
I wrote an application in which I use the PLPDF package to generate PDF screens. Initially, the last few commands in my code looked like:
owa_util.mime_header('application/pdf',false);
htp.p('Content-Length: ' || dbms_lob.getlength(l_blob));
owa_util.http_header_close;    
wpg_docload.download_file(l_blob);The variable l_blob is the PDF blob object generated by PLPDF. The PDF is being formed from a cursor for loop further up in my code (not displayed here) that is SELECTing from a table. The above code displays the generated PDF on to a popup page in my application. At that point, the user can click the "File->Print" menu to send the displayed PDFF to the default printer.
However, my requirements are that I may have multiple PDFs generated from my for loop and would like to have each of these PDFs sent to the default printer is one go rather than force the user to have to display and print each one separatlely.
And so I modified the above code so that the PDFs created by the PLPDF package are being inserted into an Oracle table rather than displayed in a popup page.
Would any one know how to send each of the PDFs stored in the table to the default printer automagically, perhaps my issuing a ctrl+p command or some such thing.
Thanks in advance for any help/code/advice.
Elie

I tried the following code that which comes directly from the Apex Stored procedure PRINT_PDF.
The APEX_UTIL.GET_PRINT_DOCUMENT function returns NULL.
declare
    v_filename varchar2(1000);
    v_pdf_blob blob;
pnum number;
begin
v_filename := 'TEST_' || to_char(sysdate,'yyyymmdd');
pnum := --Hidden from Post;
dbms_output.put_line('Security ID: ' || pnum);
wwv_flow_api.set_security_group_id(p_security_group_id=>nvl(wwv_flow_application_install.get_workspace_id,pnum));
v_pdf_blob := APEX_UTIL.GET_PRINT_DOCUMENT (
                                       p_application_id      =>  121,
                                       p_report_query_name   => 'QS_CERT_QUERY_TEST',
                                       p_report_layout_name  => 'QS_CERT_QUERY',
                                       p_report_layout_type  => 'xsl-fo',
                                       p_document_format     => 'pdf');
insert into printed_pdfs (filename, stored_pdf, record_created_By_person, record_created_on_date)
                  values  (v_filename||'.pdf', v_pdf_blob, 'Name', sysdate);
end;
Any idea on what is wrong or how to make it work.

Similar Messages

  • Can I batch print PDF files with Adobe Acrobat Reader X

    can I batch print PDF files with Adobe Acrobat Reader X?  I have tried from Windows Exploer (Windows XP) and it looks like the files are opening but they do not print.
    Pat

    Very strange!  What is your installed Reader version?
    Try disabling Protected Mode in Adobe Reader [Edit | Preferences | Security (Enhanced)].

  • Batch Printing PDF files in Sharepoint

    We are migrating our production documents into an existing WSS2.0 environment.  The documents are mainly .PDF files and I am trying to find a way to allow a user to select a subset of files within a view and once done, submit all of them to be printed. 
    I envision a Windows File Explorer window that a user could check only the files desired and then click a single print button to launch the batch print.  I have done some searching, but the the commercial tools I have found are very expensive.  Anyone
    know of another way to accomplish this need?

    Hi Vondie,
    I found a post in this thread may helpful for your issue.
    http://social.msdn.microsoft.com/Forums/en-US/csharpgeneral/thread/8ce3dd94-ff2c-4c3c-ba85-f67b9dd2f2e8/
    It is suggested you to start by looking into the
    PDF Forms
    parser on Code project to get you started. Here is a list of open
    source pdf software for C# that might help you.
    Or try to post a how to bulk print PDF questions in the
    Adobe Online Forums.
    Thanks for your understanding.
    Lambert Qin
    TechNet Subscriber Support
    in forum
    If you have any feedback on our support, please contact
    [email protected]
    Sincerely,
    Lambert Qin
    Posting is provided "AS IS" with no warranties, and confers no rights.

  • How to batch upload PDF files into database BLOB

    Hello.
    I have a requirement to batch upload PDF files into BLOB column of an Oracle 8.1.7 table from Forms 6i Web. The content of the blob column (ie. the PDF content) MUST be displayable from all client software (eg. Oracle Web forms, HTML forms, etc.)
    Our environment is
    Middle-tier is 9iAS on Windows/2000
    Database is Oracle 8.1.7.0.0 on VMS
    Oracle Web Forms 6i Patch 10
    Basically my Oracle web form program will display a list of PDF files to upload and then the user can click on the <Upload> button to do the batch upload. I have experimented the following approaches but with no luck.
    1. READ_IMAGE_FILE forms built-in = does NOT work because it cannot read PDF file. I got error FRM-47100: Cannot read image file
    2. OCX and OLE form item = cannot use this because it does NOT work on the Web. I got error FRM-41344 OLE object not defined
    3. I cannot use DBMS_LOB to do the load because the PDF files are not in the database machine.
    4. Metalink Note 1682771.1 (How to upload binary documents back to database blob column from forms). When I used this, I got ORA-6502 during the hextoraw conversion. In using this solution, I have downloaded a bin2hex.exe from the Google site. I've noticed that when I looked at the converted HEX file, each line has the character : (colon) at the beginning of each line. I know the PDF file has been converted correctly to HEX format because when I convert the HEX file back to BIN format using hex2bin.exe, I'm able to display the converted bin file in Acrobat Reader. When I removed the : (colon) in the HEX file, I did NOT get the ORA-6502 error but I CANNOT display the file in Acrobat Reader. It gives an error "corrupted file".
    5. upload facility in PL/SQL Web toolkit - I tried to automatically submit the html form (with htp.p) but it does NOT load the contents of the file. I called the URL from Oracle forms using web.show_document. There seems to be issues with Oracle Web forms (JInitiator) and HTML (+ htp.p).
    The other options I can think of at this point are:
    1. Use SQL*Loader to do the batch upload via SQL*Net connection and use HOST() built-in from Oracle Webforms to execute SQL*Loader from the 9iAS.
    2. Write a Visual Basic program that reads a binary file and output the contents of the file into a byte array. Then build a DLL that can be called from Oracle webforms 6i via ORA_FFI. I don't prefer this because it means the solution will only work for Windows.
    3. Write a JSP program that streams the PDF file and insert the contents of the PDF file into blob column via JDBC. Call JSP from forms using web.show_document. With this I have to do another connection to the database when I load the file.
    4. Maybe I can use dbms_lob by using network file system (NFS) between the application server and VMS. But this will be network resource hungry as far as I know because the network connection has to be kept open.
    Please advise. Thank you.
    Regards,
    Armando

    I have downloaded a bin2hex.exe from the Google site.
    ... each line has the character : (colon) at the
    beginning of each line. I'm afraid it isn't a correct utility. I hope you'll find the source code of a correct one at metalink forum:
    Doc ID: 368771.996
    Type: Forum
    Subject: Uploading Binary Files: bin2hex and hex2bin do not reproduce the same file
    There is some links to metalink notes and some example about working with BLOB at http://www.tigralen.spb.ru/oracle/blob/index.htm. Maybe it helps. Sorry for my English. If there is any problem with code provided there, let me know by e-mail.

  • How to directly print PDF file(which is stored in SAP) in ABAP report?

    Hi experts,
    I searched SDN for printing PDF file but everything is about OTF to PDF and to use fm: CONVERT_OTF which is not the solution for my problem.
    I have to build ABAP report which will take the PDF file attached to SAP document (CV02N) and print it.So, which function module or program can I use to print the PDF file?
    Thank you very much.
    Kind regards,
    Danijela

    Dear
       this is the code for down load smartform for PDF format. its working properly
    2nd way is
    set your Acrobat Printer as your default printer
    when you print select printer as LOCAL
    then you will file dialog box for Naming PDF
    DATA  :  T_OTF          TYPE ITCOO OCCURS 0 WITH HEADER LINE.
      DATA  :  WA_CTRLOP      TYPE SSFCTRLOP.
      DATA  :  WA_OUTOPT      TYPE SSFCOMPOP.
      DATA  :  T_OTFDATA      TYPE SSFCRESCL.
      DATA  :  T_PDF_TAB      LIKE TLINE OCCURS 0 WITH HEADER LINE.
      DATA  :  V_FILESIZE     TYPE I.
      DATA  :  W_BIN_SIZE     TYPE I.
      WA_CTRLOP-GETOTF = 'X'.
      WA_CTRLOP-NO_DIALOG = 'X'.
      WA_OUTOPT-TDNOPREV = 'X'.
      CALL FUNCTION P_LV_FNAME
        EXPORTING
          OUTPUT_OPTIONS     = WA_OUTOPT
          USER_SETTINGS      = 'X'
          CONTROL_PARAMETERS = WA_CTRLOP
        IMPORTING
          JOB_OUTPUT_INFO    = T_OTFDATA
        EXCEPTIONS
          FORMATTING_ERROR   = 1
          INTERNAL_ERROR     = 2
          SEND_ERROR         = 3
          USER_CANCELED      = 4
          OTHERS             = 5.
      T_OTF[] = T_OTFDATA-OTFDATA[].
      CALL FUNCTION 'CONVERT_OTF'
        EXPORTING
          FORMAT                = 'PDF'
          MAX_LINEWIDTH         = 132
        IMPORTING
          BIN_FILESIZE          = W_BIN_SIZE
        TABLES
          OTF                   = T_OTF
          LINES                 = T_PDF_TAB
        EXCEPTIONS
          ERR_MAX_LINEWIDTH     = 1
          ERR_FORMAT            = 2
          ERR_CONV_NOT_POSSIBLE = 3
          OTHERS                = 4.
      DATA  :  LV_DOWN_FILE TYPE RLGRAP-FILENAME.
      DATA  :  LV_TEXT      TYPE STRING.
      CASE SSCRFIELDS-UCOMM.
        WHEN 'REPRUNMOLD'.
          CONCATENATE '(' SO_SCHDT-LOW '-' SO_PLANT-LOW ')' INTO LV_TEXT.
          CONCATENATE '\\lkdb01\FTP-Loadstar\0.PP_Planning\ZPP014\Run_Moulds\' SY-DATUM '-' SY-TIMLO '-' 'Running Mould' '-' LV_TEXT '.pdf' INTO LV_DOWN_FILE SEPARATED BY SPACE.
        WHEN  'REPLINESIT'.
          CONCATENATE '(' SO_SCHDT-LOW '-' SO_PLANT-LOW '-' SO_LINE2-LOW ')' INTO LV_TEXT.
          CONCATENATE '\\lkdb01\FTP-Loadstar\0.PP_Planning\ZPP014\Line_Situation\' SY-DATUM '-' SY-TIMLO '-' 'Line Situation' '-' LV_TEXT '.pdf' INTO LV_DOWN_FILE SEPARATED BY SPACE.
      ENDCASE.
      CALL FUNCTION 'WS_DOWNLOAD'
        EXPORTING
          BIN_FILESIZE            = W_BIN_SIZE
          FILENAME                = LV_DOWN_FILE
          FILETYPE                = 'BIN'
        IMPORTING
          FILELENGTH              = V_FILESIZE
        TABLES
          DATA_TAB                = T_PDF_TAB
        EXCEPTIONS
          FILE_OPEN_ERROR         = 1
          FILE_WRITE_ERROR        = 2
          INVALID_FILESIZE        = 3
          INVALID_TYPE            = 4
          NO_BATCH                = 5
          UNKNOWN_ERROR           = 6
          INVALID_TABLE_WIDTH     = 7
          GUI_REFUSE_FILETRANSFER = 8
          CUSTOMER_ERROR          = 9
          OTHERS                  = 10.
      IF SY-SUBRC <> 0.
        MESSAGE  'File not downloaded succesfully' TYPE 'I'.
        EXIT.
      ELSE.
        MESSAGE 'PDF File downloaded succesfully' TYPE 'I'.
      ENDIF.
    ENDFORM.                    " Print_PDF
    Rewards if useful.

  • How to duplex print pdf file on hp 1320 using upd pcl5 on windows 7 ?

    I am running Windows 7 Professional (64bit), with a HP laserjet 1320 using driver HP UPD PCL5 (v5.5.0.12834), with Adobe Acrobat 9 Pro v9.5.2 and MS Word 2010. When I print a Word 2010 file I can choose duplex printing (print on both sides) and everything works fine. However, when I open a PDF file, click FILE then PRINT then PROPERTIES the PRINT ON BOTH SIDES option shows "none" and no other option is shown. I searched Adobe support and it says duplex printing is controlled by the printer driver, not Adobe software. I have uninstalled & reinstalled the UPD PCL 5 driver two times already but still the same problem of not being able to choose duplex printing for any PDF document - yet it works for MS Word. Any ideas ? Thanks 

    How do I duplex print on an HP 1320 printer that uses windows 7 (64 bit) system?

  • Automator Script - How to Batch Convert PDF files to max 200x200px JPG Files

    I have tried several different Automator scripts and can't seem to get it right.
    Each day I have 25 different PDF files. I need to convert the first page of each PDF file to a max width and height of 200x200px jpg file (not jpeg).
    In automator, how do you do a batch convert of the first page of PDF files to a max width and height of 200x200 JPG files?
    Thanks!

    Try
    GraphicsMagick.

  • How to batch print indesign files to ps?

    In Windows OS,
    I have a lot indesign files needed to print to postscript files -->PDF.
    I tried to include them together in a book file and print them multiply, but it turned out that the page information just displayed the book's name, not every document's info.
    How could I achieve the goal through scirpting?
    p.s.
    I just hope zevrix's BatchOutput has a Windows version.

    SuperMacGuy wrote: "I'd like to very politely ask Olav, Dov, and anyone else to not question why any of us need to Postscript > PDF versus export a PDF directly from InDesign. I, and numerous others, have requirements of our workflow or output that we can't change, or technical problems that are only overcome by PS-PDFing. I understand that you also may want to inform others that direct PDF export might be better, that's OK too."
    As long as I know that it's a requirement for a particular poster, I won't bring it up (though I might forget from time to time). You'll note that as soon as the original poster wrote: "It was just a workflow we have to obey... " I did not press the matter any further.
    But it's a widespread and false assumption that deserves challenging, so I will not stop questioning it. There is so much "information" out there about InDesign's PDF export that is simply wrong, based on superstition, hearsay, incomprehension, and pure stupidity that I have to "question why," just as a public service. It has nothing to do with "company line" (which I routinely violate anyway). It's just the truth.
    All of the "problems" with direct PDF export are traceable to either ignorance or antiquated equipment/workflows. I've worked in plenty of places where I had to deal with the latter under policies set by the former, without recourse to argument, so I do understand the problem!
    So we're cool, I hope.
    Thanks,
    Ole

  • How do I print PDF files in preview with the added annotations?

    Is there a way to print out the document with the added notes that are next to the slides?

    When you add notations to a PDF document, you need to hit "save" for every page before doing anything else. If you forget to save the changes for each page, they will not re-appear. So, if you save the change, it should then print with your notations.

  • How to Upload a PDF file into BLOB column in a table using Forms 9i

    Can anyone tell me how to upload a PDF file from client system using File dialog window and store its content in BLOB column in a table. The file to be uploaded will be in client side.

    Hi,
    please, search a bit on the forum before do a question:
    Just searching by "upload blob pdf" ...
    How to batch upload PDF files into database BLOB
    Regards,
    Jose.

  • Printing PDF files double-sided

    Using an HP Photosmart Plus B210a - how do I print  PDF files double-sided.  I can print Word documents etc. this way but do not seem to have the option when opening a PDF file.
    This question was solved.
    View Solution.

    Hi,
    You might experiment with a page or two first.
    1.Choose File > Print.
    2.From the Subset pop-up menu in the Print Range area, select Even Pages Only.
    3.Click OK or Print.
    4.If the total number of pages is odd, add a blank sheet so the final odd page has a sheet to print on.
    5.Put the stack of printed paper back into the supply (source) paper tray so that the unprinted sides print. Point the top of the pages toward the printer. Make sure that the edges of the paper stack are square.
    6.Choose File > Print and select Odd Pages Only from the Subset menu.
    7.Select the Reverse Pages option. In this scenario, the Reverse pages option ensures that the page sequence is correct.
    8.Click OK or Print.
    Say Thanks by clicking the Kudos Star in the post that helped you. Please mark the post that solves your problem as Accepted Solution.
    I am employed by HP

  • How to print PDF file with hp-ux 11.31 on itanium

    We finished upgrade from 11.5.7 to 12.1.1.
    With 11.5.7 ( pa-risc hp-ux 11.23 ) we print our pdf file in using acroread to convert them in postscript and print them to printer.
    In our 12.1.1 environment ( itanium hp-ux 11.31 ) ; acroread is not available on itanium.
    Which tool can we use to be able to print PDF file on itanium ( itanium pdf to postscript tool ) free
    Thanks
    Marc

    Pl see MOS Doc 778970.1 (How to Print PDF/UTF8 in R12?)
    HTH
    Srini

  • How to print pdf files not using acrobat product?

    i just want to print pdf files,but not want to use the adobe acrobat or acrobat reader,just want to write a tools print pdf files directly.

    > no i just want to print it,not need to read it.can you help me?
    Well, the problem is to print it you need to be able to read it. Something needs to convert it into a format the printer can understand (most printers are PostScript or PCL).
    I'm not sure you entirely understand what a PDF file is. It's not a fancy text file. It's a binary format. Saying "I want to print a PDF without a PDF interpreter" is like saying "I want to run an EXE without Windows". You need software to interpret the format.
    You certainly can write your own software to interpret the PDF format, convert it to a print language and output that to a printer, but as Aandi said you will need to start by reading the PDF Reference so you know how the inside of a PDF file works, and it will most likely take several years of development even for a seasoned, expert programmer. It's just not as simple as "Printer, meet PDF. PDF, meet printer."

  • How to print PDF files

    How to print PDF files????

    Please see FAQ: How to print a PDF file from Adobe Reader Touch.
    If you don't see the Print button in the toolbar, please update to the latest version of Adobe Reader Touch.
    FAQ: How to update Adobe Reader Touch to the latest version
    The latest version (1.2) also includes newly supported features such as Commenting (adding Sticky Notes, Highlight, Strikeout, and Underline), Save/Save As, and Go to Page.
    Here's the blog post by Dennis Griffin (Product Manager for Adobe Reader for Tablets and Smartphones).
    Adobe Reader Touch for Windows 8 adds Comments and More

  • How do i view and print pdf file in mac osx with ff4.0?

    How do i view and print pdf files in ff 4.0 on a mac with osx. for some reason the updated ff version does not support it. Makes no sense that something that worked in an earlier version now does not...
    Thanks,
    Ron

    Please don't post the same question multiple times!

Maybe you are looking for

  • View Word and PowerPoint in browser no longer working

    Hi There, I have SharePoint 2010 environment. I configured Word Viewing Service and PowerPoint service accordingly and all working perfectly. But recently it didn't work any more. I deleted services and recreate services, even stop and restart the se

  • Error occurred during back up

    "iTunes could not back up the iPhone "iPhone" because an error occured. I recently brought my old Mac into the Apple store to have everything transfered over to my new Mac. When I plug my iPhone into my new computer I get this message. I try to back

  • Macbook pro discharging batteries

    I have two Macbook pros (2,2) both work fine from ac and charge the batteries, however one was losing the charge much faster when not connected to ac. Battery %age dropped from 100% to 74% in 30mins. The other one takes nearly an hour for the same. T

  • User exit: sales order  VA01: Customer number

    Hi friends, While creating Sales order, before saving the document, I need to check the Customer (Sold to pary?) details in KNEX table. KNEX-KUNNR KNEX-TDOCO KNEX-DHRCO. if condition fails, I need to display an error message V1525, which should conta

  • Ipad - Sync photos and it will delete Apps..what the **** is going on

    I have updated both my iphone and Ipad2 to latest operating system, but tell me apple what the **** were you thinking? 1) Now I can't sync my photos on to my Ipad from my laptop, if I do it will delete all my Apps! 2) Icloud appears to be a waste of