简体   繁体   English

如何使用 javascript 在 Adob​​e Acrobat DC 中打开导航窗格?

[英]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?有没有办法在 Adob​​e Acrobat DC 中使用 javascript 打开特定的导航窗格? 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.我有一个按钮,允许用户将文档附加到 PDF 文件,效果很好。 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? 有没有一种方法可以在Adobe Acrobat DC中使用javascript打开特定的导航窗格?

No. Acrobat JavaScript cannot control the navigation panes. 否。AcrobatJavaScript无法控制导航窗格。

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.在操作选项卡中,在选择操作下选择运行 Java 脚本。 Click Add and copy and paste this text:单击添加并复制并粘贴此文本:

this.viewState = {overViewMode:7};

It works perfectly.它完美地工作。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何在 Adobe Acrobat DC 的 JavaScript 脚本中定义字符串的编码 - How can I define the encoding of strings in JavaScript script in Adobe Acrobat DC 如何在Adobe Acrobat中使用Javascript运行Python脚本? - How can i use the Javascript in adobe Acrobat to run a Python Script? adobe acrobat dc文档级javascript - adobe acrobat dc document level javascript Adobe Acrobat DC Pro中的JavaScript帮助 - JavaScript Help in Adobe Acrobat DC pro 在Adobe Acrobat X Pro中,如何使用javascript以acrobat pdf格式预填充文本字段? - In Adobe Acrobat X Pro, how do I use javascript to prefill text fields in an acrobat pdf form? 如何使用Acrobat Javascript在Adobe Acrobat中创建真实的链接注释 - How can I create a real link annotation in Adobe Acrobat using Acrobat Javascript 如何使用 JavaScript 在 Adobe Acrobat Pro DC 中根据关键字删除 PDF 页面? - How to delete PDF pages based on keywords in Adobe Acrobat Pro DC using JavaScript? Adobe Acrobat Pro Dc-如何使用“按名称获取”命令在3D模型树中显示所有分支 - Adobe Acrobat Pro Dc - How to use get by name command to show all brench at the Model Tree for 3D Adobe Acrobat Pro DC JavaScript字段属性无法传播 - Adobe Acrobat Pro DC JavaScript field properties not propagating 在Adobe Acrobat 9中,如何在JavaScript控制台中使用正则表达式搜索pdf文本? - In Adobe Acrobat 9, how do I use a regex in the JavaScript Console to search the text of a pdf?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM