Skip to main content
Participating Frequently
May 29, 2020
Question

Choosing between Javascript and Plugin Development using Acrobat DC SDK

  • May 29, 2020
  • 2 replies
  • 2358 views

Hello everyone, 

 

I am a beginner in developing Acrobat functionalities and have been provided with this task of having a button added to the toolbar , which when clicked , a popup should appear with a button , which when clicked does two things  : 1) Makes a post request to a server  and 2) Launches  a particular web page.

 

After going through the Acrobat SDK documentation, I found that Javascript provides methods for two of these functionalities i.e. namely making a post request (using Net.HTTP object) and launching a web page (using launchURL). But the issue with Javascript was , it is not possible to add the button directly to the toolbar, yes I know we can customize the toolbar by adding the add-on tool to the toolbar but that requires some hand work.

 

 

On the other hand , the Acrobat SDK documentation provides for adding a button to the toolbar directly using plugins, but I had also read that plugins do not provide support for web services. 

 

 

So given the use-case  and the requirements, what would be your suggestion?

 

Specifically it would be nice if you could answer the following questions:

1) Which one would be better to go with Javascript or plugin development ?

 

Plugin development related queries:

2) Is it possible to develop a plugin and save it in the plug_ins folder of Acrobat Reader DC and see the plugin in action OR is it that Acrobat Professional is needed to develop plugins ? (this is only to know if I can develop plugins locally on my laptop or would I need Acrobat Pro even for development purposes)

 

3)Would it be possible to make post requests and launch webpage via plugin development ?

 

This topic has been closed for replies.

2 replies

Thom Parker
Community Expert
Community Expert
May 29, 2020

The NET.HTTP object does not operate in Reader. So you can't use it there anyway. Developing a plug-in for Reader requires permission from Adobe and a big fee. So you've got some road blocks.

 

On the other hand. The JavaScript "doc.submitForm()" function can do a HTTP post, what exactly is it you are trying to post? 

Thom Parker - Software Developer at PDFScriptingUse the Acrobat JavaScript Reference early and often
Participating Frequently
May 30, 2020

" The NET.HTTP object does not operate in Reader. So you can't use it there anyway "

 

Yes I had read this in the documentation but anyways we are aiming at adding these functionalities for Acrobat Pro. So just to make things clear , our company has  Acrobat Pro for all of its employees, but as of now the developers do not have access to making changes in folders such as plug_ins (for developing plugins) and Javascripts (for developing scripts), for security reasons. We were able to develop scripts and see the functionality working , thanks to the user-level javascripts folder , where we could make changes.

 

"Developing a plug-in for Reader requires permission from Adobe and a big fee."

 

I had read this statement in the documentation : " When Acrobat or Acrobat Reader starts, it scans the plug_ins folder (in the same directory as the Acrobat executable) for DLLs with the extension .API. " and thus assumed that I would be able to develop plugins locally  without any fee and see the output as well (in my case , getting a button attached to the toolbar), is my assumption wrong ? As I have stated that we cannot make changes in the plug_ins folder of the Acrobat Pro that the company provides, so I just wanted to know if I would be able to develop plugins locally using the Acrobat Reader DC that I have on my personal desktop. I hope that I could make my question clear.

 

Legend
May 30, 2020

Your quote shows how Acrobat and Reader scan for API files. Reader then checks plugins have a license from Adobe. License fees are by negotiation and Adobe only approve plugins which work with their business model. (A plugin which gives services that could be got by buying Acrobat for each user would be rejected probably). 

Plugins cannot add to the Quick Bar. They can create tools that the USER CAN ADD MANUALLY. They can add menu items. 

Thom Parker
Community Expert
Community Expert
May 29, 2020

The Acrobat SDK does not provide support for web services because it's for Acrobat, not for accessing the web.  If you want perform a post, then add a library for doing that your project. The plug-in is just a DLL. You can access whatever system services or libraries you need, just as long as they don't violate security in Acrobat. 

Thom Parker - Software Developer at PDFScriptingUse the Acrobat JavaScript Reference early and often
Participating Frequently
May 30, 2020

Okay , thanks a lot for making this clear.