Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.

Button converting form PDF to Chrome in Workspace

Avatar

Level 7

I have four buttons in the form. When I open it in Workspace, how does it determine which button to convert to the Chrome?

Aditya

7 Replies

Avatar

Former Community Member

Assuming by Chrome you mean the Workspace flash container. It's the button that performs a submission.

Avatar

Level 7

What if there are two buttons doing the submission. For example, the form has one button doing an HTTP Post to a servlet which invokes workflow. And, the second button needs to be used within workspace.

Aditya

Avatar

Level 7

Is there a way to submit using javascript OR specifying the URL using a script. This way the same button to two different URLs with an if statement?

Aditya

Avatar

Level 3
Level 3

Use a regular button and write the following code on the click event of  button:

if(condition)

{

    

     xfa.connectionSet.DataConnectionName.execute(0);

}

if(condition)

{

    

     xfa.connectionSet.DataConnectionName.execute(0);

}

Thanks

Avatar

Level 7

Thanks aks@lc!

How would I call a servlet? I need to submit the form as a PDF to the servlet.

Aditya

Avatar

Level 10

Hi Aditya,

Place a button on your PDF and set teh control type to Submit

On submit panel, set your Servlet URL and change Submit As type to PDF

servlet.png

Nith

Avatar

Level 7

Nith - The form has two submit buttons. I am unable to convert the correct submit button to the flash template.

Button 1 - Submits to the Servlet

Button 2 - Submits to the Workspace server

After the form is submitted (externally) it pops up in Workspace, I want the second button to convert to the flash template but, only the first buttons converts.

Hence, I need to figure out a way to either change the submit URL dynamically (and retain one button) or force the second button to convert.

Aditya