1

I want to run an Acrobat Javascript inside of Adobe Acrobat. In that script I want to create a link annotation.

This can be done easily enough, but using the "addLink" function in the document object, but this type of link only works with a Javascript action. In other words, when the link is clicked, a piece of Javascript is executed by Acrobat to jump to a new location or URL.

This is not what I want, what I want is to create a Link annotation that contains a simple URL, and not an action Javascript.

Is this possible using the Adobe Acrobat API? And if so, how?

(please don't suggest using a plug-in, I know about Acrobat plug-ins but that's not what I'm looking for right now).

David van Driessche
  • 6,602
  • 2
  • 28
  • 41

2 Answers2

0

Without further digging around in the documentation, I don't see a way to programmatically add an Action to a link; all I get is a JavaScript action (which could make use of, of course, getURL() or launchURL()).

There might be a two-step process, which uses FDF to inject the action, but I am not positively sure whether it would work with links, but only with form fields.

Max Wyss
  • 3,549
  • 2
  • 20
  • 26
0

It's not possible with the Acrobat JavaScript API.

joelgeraci
  • 4,606
  • 1
  • 12
  • 19