These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

Batch search text and get location

rpacheco
Registered: Jul 10 2010
Posts: 4

I will like to batch process to search text and find a pharase like "sign here", get its location in the page to use it as refernce to then place a custom stamp sign.

Rics

My Product Information:
Acrobat Standard 8.0, Windows
Script Kitty
Registered: Jul 9 2010
Posts: 19
Search through all of the text on the page using getPageNumWords and getPageNthWord or getPageNthWordQuad, then use the addAnnot or whatever function you need to do in that relative coordinate space to add the actual "stamp sign".

When you search for text you will have to use a "regular expression":
http://www.regular-expressions.info/reference.php
http://www.jslab.dk/tools.regex.php

Here is an example of finding text based off of regular expressions and quad location:
http://www.acrobatusers.com/tutorials/2008/07/auto_redaction_with_javascript

I hope this helps,