0

I am attempting to search a PDF file of its contents. The pdf files Im most interested in are construction sheets so they are not orderly like an essay email with words. However in a pdf viewer I am very easily able to use a command F to find what I need and all text seems to be searchable. I want to be able to replicate that same function in python in order to help automate some things ive been doing. Ive attempted to use libraries such as PyPDF2 to extract the text from these files however there was no luck in doing this. Is there a way to extract that text from the pdf like I am able to in a pdf viewer?

  • what failed when you tried to use PyPDF2? do you have any code to show? Most solutions would involve extracting the text and then searching it. – Stuart Aug 26 '20 at 22:02
  • 1
    Does this answer your question? [Searching text in a PDF using Python?](https://stackoverflow.com/questions/17098675/searching-text-in-a-pdf-using-python) – Stuart Aug 26 '20 at 22:03

0 Answers0