nikivi Posted August 15, 2017 Share Posted August 15, 2017 (edited) This workflow allows you to search through PDF files. However I really wish I could search through the contents of these PDF files. I am not really sure how I can do that. I searched on this forum too but did not find anything on this. Thank you for any help. Edited August 15, 2017 by nikivi Link to comment
GuiB Posted August 15, 2017 Share Posted August 15, 2017 Hi @nikivi, I think this do what you want... To search inside content of files you need to add a "kMDItemTextContent" in the Metadata Field of the File Filter object. I removed all the other fields so it only search inside the content. Download and try: https://nofile.io/f/rwPDejpTrB5/search+pdfs.alfredworkflow nikivi 1 Link to comment
nikivi Posted August 15, 2017 Author Share Posted August 15, 2017 This is awesome. Thank you a lot @GuiB. Link to comment
LynneS Posted October 30, 2017 Share Posted October 30, 2017 (edited) This is brilliant! I've been putting off getting out of Evernote because I have a ton of PDFs and Evernote can search their text. You may have just saved me the subscription price. Can I buy you a hypothetical cup of coffee? Edited October 30, 2017 by LynneS Link to comment
dfay Posted October 30, 2017 Share Posted October 30, 2017 Spotlight, built into the last 8 or so iterations of macos, also searches PDF content... Link to comment
GuiB Posted October 31, 2017 Share Posted October 31, 2017 @LynneS note that Alfred and Spotlight would search inside PDF when the text is inside the Metadata of the file. I mean, if you have PDFs that contain only images (ex: simple scanned PDF where no optical character recognition (OCR) was done), then they won't be able to search the content. I don't really use Evernote, but if I remember well, they would scan the PDF to extract the characters from it to make it searchable (they have an OCR feature built-in). However, this depend on the PDFs that you use, if you are already able to search for them in Alfred or Spotlight, then you are good to go! But, if some of your PDF doesn't embed the characters but only the images, then you would need an extra application that do an optical character recognition and add it to the PDF to make it searchable (some that I know that should do the job: PDFpenPro, DEVONthink Pro Office, OCRKit, Prizmo, or search for OCR applications). If you're not sure if the file contains the character, try opening it in Preview and try to select some text. If you are able, then you should be fine, if not, then your PDF must contains only images. Link to comment
LynneS Posted October 31, 2017 Share Posted October 31, 2017 Thanks GuiB, that's good to know. I had noticed the two different kinds of PDF, but I didn't realize the difference with respect to searching. Fortunately, for most of the ones I am interested in, I can select the text. Link to comment
deanishe Posted October 31, 2017 Share Posted October 31, 2017 1 hour ago, GuiB said: PDFpenPro, DEVONthink Pro Office, OCRKit, Prizmo PDFScanner is very good, and a lot cheaper than any of those. GuiB 1 Link to comment
mmvv Posted December 13, 2018 Share Posted December 13, 2018 Hello, Does this workflow yield more results than the "inside files" option within "File Search" (v.3.7 [938])? On 8/15/2017 at 3:09 PM, nikivi said: This workflow allows you to search through PDF files. However I really wish I could search through the contents of these PDF files. I am not really sure how I can do that. I searched on this forum too but did not find anything on this. Thank you for any help. 1 Since... On 10/30/2017 at 12:03 PM, dfay said: Spotlight, built into the last 8 or so iterations of macos, also searches PDF content... Thanks! Link to comment
Chris_YZX Posted May 26, 2019 Share Posted May 26, 2019 I can't download this file in this website,is it expired? could you save it in other website?@GuiB Link to comment
GuiB Posted May 26, 2019 Share Posted May 26, 2019 @Chris_YZX, I can still access it from the link above, but here is from another link/website in case this better work for you: https://d.pr/f/er1jIz Link to comment
Dan-Mulligan Posted March 18 Share Posted March 18 Am I understanding this correctly? Or barking up the wrong tree... The bottom one is configured to search via "kMDItemTextContent" "The value can be (query), (var:varname) or constant strings. The constructed query is grouped by value type, for example: (query OR query) AND (var AND var) AND (const AND const)" (I don't understand what this means... Should I create a {const} parameter to find a string...?) Am I mistaken in thinking this Workflow should be able to search for a specific string of text within a library of PDFs and present the result that matches the string...? For example, I've decided I want to find this random paragraph contained within a PDF: "In the silence of the early morning, I’m in my office, preparing for the day’s trading." So in theory I was hoping the Workflow would return the result, Best Loser Wins, since that's the PDF where this sentence was taken from. But obviously no such luck (I'm misguided or I haven't configured it correctly...) When I paste the quote into the Workflow, it can't find any PDF containing the phrase and so just returns these default search options: Can you shed some light... Ideally I'm trying to see if it's possible for me to link from ANKI (Flashcard / Memory Aid) to specific quotes within PDFs via Alfred... If anyone knows how I might go about it, I'd be very grateful. (Is it possible to hyperlink to anchors within a PDF...? Which admittedly is another topic altogether...!) Much obliged, Dan Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now