These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

Submit PDF + Attachments to Servlet

oscarp
Registered: Feb 5 2007
Posts: 4

I have a PDF form created in LiveCycle Designer 8. When a user opens this form they attach other documents to it (images, spreadsheets, etc). How do I submit the Original PDF form + it's attachments to a Servlet? Do I do this in LiveCycle Designer using a HTTP Submit Button or in Acrobat 8?

My Product Information:
Acrobat Pro 8, Windows
thomp
Expert
Registered: Feb 15 2006
Posts: 4411
You're best option is to use the AcroForm submit function from a button on your LiveCycle Document. Add this code to the click event script

event.target.submitForm({cURL:"Your URL",cSubmitAs:"PDF"});
This will only work on Reader if the Document has been "Save" Enabled, which can only be done from Acrobat 8, or one of the LiveCycle Servers.


Thom Parker
WindJack Solutions
[url=http://www.windjack.com]www.windjack.com[/url]

The Acrobat JavaScript Reference, Use it Early and Often
[url=http://www.adobe.com/devnet/acrobat/]http://www.adobe.com/devnet/acrobat/[/url]

Thom Parker
The source for PDF Scripting Info
www.pdfscripting.com
Very Important - How to Debug Your Script

nw
Registered: Mar 26 2008
Posts: 1
I'm looking at a very similar requirement and I was wondering how you retrieved the PDF from the request object. The servlet is expecting the data to be encoded by multipart/mime, but it is being encoded by application/pdf format. Any help appreciated.