Skip to main content
Known Participant
Jan 16, 2017 8:08 AM UTC
Question

How to delete a Highlight annotation?

Hello,

I have created a plugin to create a highlight annotation using COS object.

Now, I want to delete that annotation by comparing the contents in it.

How can I achieve this?

I am using:

SDK : Acrobat Pro SDK(Version1)

Product: Acrobat Pro DC(Version2015)

Platform: Windows 7

Thanks,

Best Regards,

Navnath

This topic is closed to new replies. Start a new post to keep the conversation going.

3 replies

Legend
Jan 16, 2017 9:55 AM UTC

Using Cos I would enumerate the annotations on each target page IN REVERSE ORDER of annotation index. Start with the Annots key in the page dictionary (optional). Compare the annotation type and other keys to find a match. Delete from the Annots array.

Translate
Legend
Jan 16, 2017 9:55 AM UTC

I think it may be mandatory to send a notification, can't recall.

Translate
Known Participant
Jan 16, 2017 11:03 AM UTC

Thank you for the reply.

I got the solution

We can use PDPageRemoveAnnot as below:

PDPageRemoveAnnot(page, PDPageGetAnnotIndex(page, annot));

Thanks.

Translate