How to highlight PDF by command line in batch?

      In this article, I will show you a method of highlighting text in PDF by command line in batch. Under this method, you can do text highlighting in PDF from application Visual C++, Visual Basic, etc.. I use software VeryPDF PDF Text Replacer, which can help you replace PDF text with text and image. In the following part, I will show you how to make it work.

Step 1. Download PDF Text Replacer Command Line

  • There are two versions stated on the website: GUI version and command line version. Here I will take the command line version for example.
  • When downloading finishes, there will be a zip file in downloading folder. Please extract it to some folder then you can check elements in it and call executable file in MS Dos Windows.
  • There are many bat files in extracted folder, simply click them then you can check software working effect.

Step 2. Highlight text in PDF by command line

  • When you run the conversion, please refer to the usage and examples in readme.txt.
  • Usage: pdftr.exe [options] <Input-file> <Output-file>
  • Here one example of highlighting text for your reference.
    pdftr.exe -searchandoverlaytext "PDFcamp Printer=>PDFcamp Printer" -overlaytextfontname "Verdana" -overlaytextfontsize 80%% -overlaytextcolor FF0000 -overlaybgcolor 00FF00 verypdf.pdf te.pdf
    When you run the conversion, please obey the rules and examples as above or else the highlighting process may fail.
    The principle of this software is that searching font needed highlighting in whole PDF file and then set highlighting fonts color. In put the full path of input PDF and then output PDF file path.
    By this software and this function, even if you need to highlight text in PDF in hundreds of pages PDF file, it can finish in a few seconds and show all the replacing information in MS Dos Windows. Now let us check one example from the following MS Dos working snapshot.

MS Dos operation
Now let us check related parameters about the conversion.

-searchandoverlaytext <string>: use this parameter to search and overlay text to PDF pages
-overlaytextfontname <string> :this parameter can help you set overlay text font name, default is 'Arial'
-overlaytextfontsize <string> : use this parameter to set overlay text font size, default is 0 for auto
-overlaytextcolor <string>    : when you need to change replace text color, please add this parameter. Set overlay text color, in Hex, default is 000000
-overlaybgcolor <string>      :different with last one, this parameter is for setting overlay text background color, in Hex, default is FFFFFF.

Now let us check the highlighting text effect from the following snapshot. During the using, if you have any question, please contact us as soon as possible.

highlight text in PDF

VN:F [1.9.20_1166]
Rating: 0.0/10 (0 votes cast)
VN:F [1.9.20_1166]
Rating: -1 (from 1 vote)

Related Posts

This entry was posted in PDF Text Replacer and tagged , . Bookmark the permalink.

3 Responses to How to highlight PDF by command line in batch?

  1. Tin says:

    I have some special characters:
    -







    I want to search text contains these characters in pdf file, and highlight them.
    For example: 8RDN20■■
    Can I do it?
    Could you please send me a command line code in this case?

    Thank you

    VA:F [1.9.20_1166]
    Rating: 0.0/5 (0 votes cast)
    VA:F [1.9.20_1166]
    Rating: 0 (from 0 votes)
    • VeryPDF says:

      Sorry, PDF Text Replacer Command Line doesn't support on special characters in the current version, please submit your PDF file to VeryPDF at http://support.verypdf.com, our support team will assist you asap.

      VeryPDF

      VN:F [1.9.20_1166]
      Rating: 0.0/5 (0 votes cast)
      VN:F [1.9.20_1166]
      Rating: 0 (from 0 votes)
  2. VeryPDF says:

    How to Highlight Text in a PDF File?

    You can use VeryPDF PDF Highlighter Command Line to highlight keywords in PDF pages easily,

    http://www.verypdf.com/app/pdf-highlighter/index.html
    http://www.verypdf.com/app/pdf-highlighter/try-and-buy.html#buy

    VN:F [1.9.20_1166]
    Rating: 0.0/5 (0 votes cast)
    VN:F [1.9.20_1166]
    Rating: 0 (from 0 votes)

Leave a Reply

Your email address will not be published. Required fields are marked *


Verify Code   If you cannot see the CheckCode image,please refresh the page again!