Results 1 to 40 of 91

Thread: PDF Reader ActiveX Control

Threaded View

  1. #1

    Thread Starter
    Addicted Member saturnian's Avatar
    Join Date
    Dec 2017
    Location
    France
    Posts
    134

    PDF Reader ActiveX Control

    This is my first post! I am an old French VB6 programmer and you will forgive me for using Google translation furiously!

    I have needed an OCX PDF viewer for a long time.

    Olaf Schmidt made me discover PDFium.dll in the following post:
    http://www.vbforums.com/showthread.p...-ImageExports)

    Thank you Olaf!

    I made the draft of an ActiveX component PDF viewer which allows
    • View PDF files
    • Print PDF files
    • Extract the text content if it exists
    • Practice Character Recognition on the PDF file in conjunction with Tesseract-OCR, open-source OCR software under Apache 2.0 license (https://github.com/tesseract-ocr/tes...ster/README.md)

    Name:  PDFReader.jpg
Views: 11760
Size:  53.5 KB

    Like Olaf, I use the PDFium version 2018-04-08 / Pdfium-x86-no_v8-no_xfa available on the build service provided by Pieter van Ginkel on GitHub here: https://github.com/pvginkel/PdfiumBu...lds/2018-04-08

    As Olaf says: "PDFium (licensed under BSD by Google / Foxit) is the only PDF-reader / viewer-tool I know of, which can be used (and deployed) also in commercial Apps ..."
    PDFium.dll must be in the same directory as the ActiveX component
    The component has no other dependency than PDFium.dll and the common VB6 files

    For Tesseract OCR, Windows installer is available on the following Wiki: https://github.com/UB-Mannheim/tesseract/wiki
    I use the 32bit version

    A Doc.pdf file in the zip lists the events, methods and properties of the control

    Besides Olaf Schmidt, I thank LaVolpe, Dilettante, The Trick, Fafalone, Ellis Dee for their modules gleaned from CodeBank !

    Update 2024/12/20

    1. This new version includes the improvement of the printing of post 29 and the display by bitblt proposed by jtw400 post 35
      PDFReader.zip
    2. I made a new version of PDF Reader that uses the new compilations of Pdfium by Benoit Blanchon.
      For this to work, it is imperative to load in the VB6 IDE complement of "The Trick" VBCdeclFix
      PdfReader.bb.zip
    3. Version with SaveAs function
      PdfReader.bb2.zip


    NB: I wanted to thank all the contributors to this forum for their work, which makes it possible to maintain VB6 and to adapt it to Windows evolution. With additional thought for LaVolpe whose codes and tools accompany my work for so many years!
    Last edited by saturnian; Apr 17th, 2025 at 12:12 PM. Reason: New version

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width