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

Hiding Annots in 8.1.3 reader via Acro 9 javascript

efos
Registered: Jan 8 2009
Posts: 63
Answered

Developing PDF in Acro 9 Pro for use on reader 8.1.3. I've got a highlight annotation I'd like to show or hide depending on the situation.

getAnnots(0)[0] or getAnnot(0,"testAnnot") both return the object, and I can read the properties in Reader; but I cannot write to hidden, noView, or opactiy. Is this a limitation of Reader? Is there another method to dynamically hide an Annotation?

I can show hide a Field via it's display property, seems odd I can't show/hide a simple annot via some method.

efos
Registered: Jan 8 2009
Posts: 63
This is a security issue. Commenting is not allowed in reader by default; so Annot properties are read only. The straightforward workaround is a bit heavy handed. 'Advanced > Extend Features in Adobe Reader...' Will turn commenting on in Reader. You have to save as a copy, and this must be the final step in your development process. It is a bit of a double edged sword, as it then appears to restrictany features in Pro that are not now accessible in reader. Editing security settings, advanced Annotations, and forms is no longer possible. You can save as a copy to undo the lockdown/unlock.In my situation this works because the user is unable to delete or alter the annots (text highlights) in question as they are under a button (which is not editable, and the selection tool can't access annots underneath it). So, that's my fix.