# Search a keyword and annotate it programmatically

**URL:** <https://pdfjs.community/t/search-a-keyword-and-annotate-it-programmatically/691>\
**Category:** Technical Support\
**Created:** [April 8, 2021, 12:14pm UTC](https://pdfjs.community/t/search-a-keyword-and-annotate-it-programmatically/691 "2021-04-08T12:14:15Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![Madhavi](https://avatars.discourse-cdn.com/v4/letter/m/ee7513/32.png) [@Madhavi](https://pdfjs.community/u/Madhavi)\
**Post date:** [April 8, 2021, 3:01pm UTC](https://pdfjs.community/t/search-a-keyword-and-annotate-it-programmatically/691/4 "2021-04-08T15:01:49Z")

</div>

Hi Logan,

When I use CoreControls.Search.Mode.PAGE\_STOP instead of docViewer.SearchMode.e\_page\_stop(as in the code snippet given by me), I get the error as: [https://nimb.ws/CmiS3a](https://nimb.ws/CmiS3a)

Can you please check for this as well?

Thank you,  
Madhavi

---

_[View the full topic](https://pdfjs.community/t/search-a-keyword-and-annotate-it-programmatically/691)._
