You must Sign In to post a response.
  • Category: Windows

    Read Password Protected PDF and extract specific portion and show it in picture box

    Hello Team,

    I am trying to upload a password protected pdf and extract specific portion of page and show the extracted section in 2 different picture box. So what would be the best PDF plugin for this stuff.

    Then brighten the section of the extracted part and print it on a pvc card using zebra printer.
  • #765183
    Hi,
    Use iTextSharp API to read PDF files.
    iTextSharp requires that the document not merely is opened with the user password but instead with the owner password
    Set PdfReader.unethicalreading = true; , so that you can globally override this permission checking mechanism.
    Please go through following links:
    http://stackoverflow.com/questions/17666577/opening-password-protected-pdf-file-with-itextsharp
    http://stackoverflow.com/questions/11014148/how-to-decrypt-a-pdf-file-by-supplying-password-of-the-file-as-argument-using-c
    Hope it helps.
    Regards,
    Shashikant Gurav
    shashikantgurav22@gmail.com

  • #765203
    using ItextSharp library you can read PDF file and then use the content of the file to as per you need.
    I think iText(Sharp) currently does not check in detail the user access permissions specified in the document's encryption dictionary but instead always requires the owner password for operations requiring certain permissions, and copying whole pages from a document definitively is one of them.
    see below link for more information
    http://stackoverflow.com/questions/17666577/opening-password-protected-pdf-file-with-itextsharp
    http://stackoverflow.com/questions/6586346/itextsharp-password-protected-pdf?rq=1

    Thanks
    Koolprasd2003
    Editor, DotNetSpider MVM
    Microsoft MVP 2014 [ASP.NET/IIS]

  • #766282
    As Prasad and Shashi mentioned, you can do this using iTextSharp.
    Also see the following post:
    https://support.leadtools.com/SupportPortal/CS/forums/44825/ShowPost.aspx

  • #766534
    I used Spire.PDF to read an encrypted PDF document through following code:

    http://pdfapi.codeplex.com/

    String encryptedPdf = @"..\Encrypt.pdf";
    PdfDocument doc = new PdfDocument(encryptedPdf, password);

  • #766868
    there are several ways to do it one is http://www.dotnetspider.com/resources/45646-How-to-read-the-Content-from-Image-Scanned-Copy-Using-Tessaract-OCR.aspx using tesseract OCR you can read the particular portion of the project.
    SRI RAMA PHANI BHUSHAN KAMBHAMPATI


Sign In to post your comments