Expand my Community achievements bar.

Learn about Edge Delivery Services in upcoming GEM session

Copying a Javascript Button from Acrobat to LiveCycle

Avatar

Level 1

I am creating a PDF (Adobe Dynamic XML Form) using LiveCycle Designer ES2 that I will upload into my organization's web-based Electronic Health Records (EHR) software for use by our staff. I have been using Adobe Acrobat Pro to design forms, however I need to use LiveCycle Designer for the current form I am building.

I cannot figure out how to recreate the custom Save button that works in Acrobat-created forms, in LiveCycle. In other words, I simply need to copy a button from an Acrobat form into the LiveCycle form I am building.

ss1.PNG

As shown in the Acrobat screen shot above, the Save Form button runs a javascript when clicked. The javascript is:

var b = this.getField("p_url");

this.submitForm({

cURL: b.value,

bEmpty: true,

cSubmitAs: "HTML"});

To clarify, the above javascript works fine. Also, the "p_url" is a variable because the vendor sometimes changes the url, so it pulls the value from the hidden field labeled p_url (seen in the top-left corner of the screen shot above). The current working url is: https://apps.welligent.com/welligent/!pdf_util.process_eform_data?p_tablet_record_id=

I seem to be unable to recreate this button in LiveCycle. I have tried creating a button and playing around with the three types (Regular, Execute, and Submit) and popping in the url mentioned above in seemingly appropriate places. I have also tried creating a script object with the javascript function above and creating an action using the Action Builder where clicking the Save button calls the function.

I hope I have included enough information, and I appreciate any help someone can offer! This form will help make a lot of people's lives easier over here.

1 Reply

Avatar

Level 2

httpsubmit.jpg

I'm not great on LC by any means but this looks to me like you could use the HTTP Submit Button and then use that URL that you've listed.