Skip to main content
rayclank
Participant
Jan 2, 2019 3:27 PM UTC
Question

How to click a button on PDF open using Acrobat SDK Javascript / Any other library

Generate a pdf using acrobat sdk javascript which does the following things:

  • - It should contain a form with two input fields alpha and beta.
  • - The form has a submit button.
  • - I want to **submit** this form (click the submit button) **on document load** (trigger of the button) of the pdf **without** any prompts or user interaction.
  • - This should submit the form data to a remote url.

The biggest challenge I am facing is:

I am unable to find a way to click a button on load of the document without any user interaction

Action: Click a button

(Can't find the button in the doc let's say using button id or button name)

Trigger: On document load

Any help/ideas are appreciated, thanks!

This topic is closed to new replies. Start a new post to keep the conversation going.

6 replies

lrosenth
Adobe Employee
Adobe Employee
Jan 2, 2019 5:04 PM UTC

You don’t need to click the button on document load – you can simply execute the Submit action on document load.

Translate
rayclank
rayclankAuthor
Participant
Jan 3, 2019 1:02 PM UTC

How to assign an action on document onload? I can't find the option to execute an action on document on load.

Translate
Legend
Jan 3, 2019 1:47 PM UTC

Create document level JavaScript. That is executed on load. Mostly it defines functions, but code outside a function is executed at that time.

Translate