Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

PDF attachment path(Embedded file path)

New Here ,
Nov 15, 2022 Nov 15, 2022

How to find pdf attachments file path? 

TOPICS
Create PDFs , Edit and convert PDFs , General troubleshooting , PDF forms , Standards and accessibility
2.3K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 15, 2022 Nov 15, 2022

Hi,

Can you share a bit more details?

The file is attached to a PDF document (not a hyperlink), correct?

Try to open the Attachment panel, from View>Show/Hide>Navigation Panes>Attachments

From there, you can open the attachment, Search for the file name in your system, ...

You raise a good point, it would be nice if the original location was listed in the columns, or something that obvious. A suggestion you can add to https://acrobat.uservoice.com.

more at Links and attachments in PDFs, Adobe Acrobat

 

EricDumas_0-1668524614855.pngexpand image

 

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Nov 15, 2022 Nov 15, 2022

Hi, 

Thanks for your quick response. 

For example I'm having XYZ.pdf .

In XYZ. pdf contains one attachment pdf file(abc.pdf).  

I can able to get XYZ.pdf file path location by using browser

(path->file:///C:/Newfolder/xyz.pdf) 

How can I get abc. Pdf path? 

Note: abc.pdf is embedded in 'xyz.pdf

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 15, 2022 Nov 15, 2022

The attachment has no path. It has only a name.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 15, 2022 Nov 15, 2022

Try this. Open the the PDF that contains the attachments.

Open a PDF attachment.

Open the Acrobat Console window, Ctrl-J

Enter and run this code in the console window

 

 

this.path

 

 

 

This will return the complete Acrobat internal file path for the attachment. It doesn't actually have much meaning because it can't be used outside of the Acrobat JavaScript environment. 

 

You'll find a tutorial on using the Acrobat Console Window here:

https://www.pdfscripting.com/public/Free_Videos.cfm#JSIntro

 

 

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

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Nov 16, 2022 Nov 16, 2022

Thanks for your information Thom. 

Now im doing PDF python project

When we try to click the clickable text(hyperlink), attachment file should be open through python Code. I have done clickable text concept but I cannot map to attachment file because I don't have exact path location. I have tried acrobat console to get path location but that path not working in python.

Now need to map the hyperlink and Attachment file. FYR i have attachment screenshot

Could you please help to solve this issue? 

Give me idea  how to find a attachment file path location or indirect path or some other way. I need to map the string text and attachment file 

IMG_20221112_105524.jpgexpand image

  •  
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 16, 2022 Nov 16, 2022
LATEST

The mechanism for opening an attachment to a PDF is dependent on the viewer in which the PDF is displayed, and/or the tool that is used to parse the PDF file format.  For example, a link inside a PDF can open an attachment by using a specially formed "destination".  Destinations are defined in the PDF specification (ISO 32000), so any compliant viewer or PDF tool will know how to handle a destination that points to an attachment. Web browsers are not known for their PDF specification compliance. Alternatively, Acrobat has a set of command line parameters. At least one of these will invoke a destination.  But this mechanism is specific to Acrobat, and will not work for any other type of PDF viewer.   If you are using a PDF SDK, or tool, of some type, then that SDK/tool has (or doesn't) a function somewhere for accessing attachments.     

 

So, in the context of PDF attachments, an ordinary HTML hyperlink has no meaning. There is no gereral purpose mechanism in the HTML specification for accessing PDF attachments. That is to say the browser has no way to know or care about PDF attachments. To do this requires a custom sever side tool, the link would need to connect the PDF file containing the attachment to an online service of some sort that would extract and return the PDF attachment. Since you are creating the website with Python, I would imagine that  this is well within your abilities.  All you need is a PDF SDK/library/tool that will provide the functionality for performing this task. 

 

 

  

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

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines