Is it possilbe to determine if a String, for example "Not Possible", exists in a PDF using CFPDF or another function inside of Coldfusion? If so, any suggestions on how to do this would be appreciated.

I think the issue I'm having is that I'm trying to do this from a binary file. I'm storing my pdfs in a database as blobs. I can successfully read them out of the database but I'm having issues incorporating the binary blob into the example above.

Ahhh, there's the kind of efficiency we want! I went with DDX from memory, as I had used it a lot in a project. I honestly didn't think of 'extractText'! Thanks for bringing it in and lightening the load.

However, at least, as I see it, the main problem remains how to go from the byte array from the database to the text file. What about something like this:

Unfortuantley I think the issue is with the PDF not the code. We use 2 differnt methods to generate the pdfs based on what we need. One of those methods is an AFP2PDF process and it appears those pdfs are somehow corrupted. The Adobe reader opens them just fine, but internal they are somehow corrupted. Similar to how a web browser is forgiving and will still display a web page if you have misformed HTML.

I got the code to work with other pdfs, just not the ones I need it to work on. I need to research how we generate those pdfs.