PDF Form Script to search pages for a word then list all page no. which doesnot contain that word.
Want a script to do the following
- Search all pages in a PDF document -
- Every page should have a certain word or phrase based on user prompt in the Adobe Actions
- If a page does not have this word or phrase, then print a list of pages that does not have this word or phrase. - want script to this step.
- this code will be used from Adobe Action Wizard -
I have got script to search and mark the word or phrase only want help for doing the last thing, i.e to show the list of pages which doesnot contain the word/phrase searched for.
//HIGHLIGHTING COLOR
var colHilite = color.yellow;
var oDoc = event.target;
var aAnnts = oDoc.getAnnots({sortBy:"Author"});
for(var i=0;i<aAnnts.length;i++)
{
if(aAnnts[i].type == "Redact")
{
aAnnts[i].type = "Highlight";
aAnnts[i].strokeColor = colHilite;
}
}
