Skip to main content
Participant
August 6, 2025
質問

I want set up buttoms when clicked on will open files attached to the pdf in the attachment pane

  • August 6, 2025
  • 返信数 2.
  • 125 ビュー

I have a multipage document, on each page is a button set up so people can click on it and open corresponding files i have attached and show up hidden in the attachments area.

返信数 2

try67
Community Expert
Community Expert
August 6, 2025

Is the other file a PDF? If so, you can easily set it up. Select as the action of the button the "Go to a page" command, then when the floating window with the "Set Link" button appears, open the attached file and browse to the desired location in that file, and then click that button, and you're done!

Thom Parker
Community Expert
Community Expert
August 6, 2025

Please provide a screenshot.  What do you mean by you've attached files and they do not show in the attachments tab?

Attachments are opened with the "doc.exportDataObject()" function.

Here's the reference entry:

https://opensource.adobe.com/dc-acrobat-sdk-docs/library/jsapiref/doc.html#exportdataobject

 

Opening attachments is a privileged operation, so it can't be done from a document button script alone. 

 

Thom Parker - Software Developer at PDFScriptingUse the Acrobat JavaScript Reference early and often