简体   繁体   中英

How can I use javascript to open a navigation pane in Adobe Acrobat DC?

Is there a way to use javascript in Adobe Acrobat DC to open a specific Navigation Pane? I've been struggling to find suitable documentation for this, so I'm asking here.

I've got a button that allows a user to attach documents to the PDF file, which works great. The issue here is that I can't set the attachments pane to stay open. I can execute the menu command to show/hide attachments, which works great for one attachment, but then as soon as you add the second attachment the pane closes, which is less than ideal (and then it opens with the third attachment, closes with the fourth, etc., etc.).

Is there a bit of code that can solve this issue, or some other setting in the document that will achieve the same effect automatically? Please note that my end users are not the most tech savvy of folks, so some way that minimizes button clicking to display the attachments is ideal.

Is there a way to use javascript in Adobe Acrobat DC to open a specific Navigation Pane?

No. Acrobat JavaScript cannot control the navigation panes.

I was researching the same problem and came across a solution using this undocumented function.

Right click on the button and go to Properties.

In the Actions tab, under Select Action choose Run a Java Script. Click Add and copy and paste this text:

this.viewState = {overViewMode:7};

It works perfectly.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM