Copy link to clipboard
Copied
Hello,
How can I execute the embedded javascript inside a pdf?
I'm using the default WPF WebBrowser control to view a pdf.
Here's the XAML:
<WebBrowser Name="_web"/>
In the .cs I do this to view the .pdf:
_web.Navigate("test.pdf");
Everything works great. The test.pdf has a javascript method called "IsComplete".
How do I call the IsComplete method?
I have Adobe Acrobat DC Pro installed.
Copy link to clipboard
Copied
Hello,
How can I execute the embedded javascript inside a pdf?
I'm using the default WPF WebBrowser control to view a pdf.
Here's the XAML:
<WebBrowser Name="_web"/>
In the .cs I do this to view the .pdf:
_web.Navigate("test.pdf");
Everything works great. The test.pdf has a javascript method called "IsComplete".
How do I call the IsComplete method?
I have Adobe Acrobat DC Pro installed.
Copy link to clipboard
Copied
Have you seen anything to suggest you should be able to?
Copy link to clipboard
Copied
I'm assuming you want to run the script from JavaScript on the web page?
You can do this through Acrobat's host container interface. I don't know how well supported it is anymore, but here is a link to a site I build many years ago to test it out.
BTW: the site doesn't work. It's supposed to trade data between two PDFs, I don't know whether its because of changes in security or supported functionality.
But you're welcome to it
Here's the entry in the Acrobat JavaScript Reference