Highlighted

Retreiving attachments from PDF

Avatar

Avatar

Aditya_S_

Avatar

Aditya_S_

Aditya_S_

23-01-2009

As you know, attachments can be added to PDF forms. I would like to know how can I retrieve these attachments and use them in Workbench ?



Thanks

Aditya

Replies

Highlighted

Avatar

Avatar

pguerett

Total Posts

7.7K

Likes

611

Correct Answer

692

Avatar

pguerett

Total Posts

7.7K

Likes

611

Correct Answer

692
pguerett

23-01-2009

You will have to use the Assembler module to get attachments. This involves writing a DDX file to manipulate the PDF to get the attachments.
Highlighted

Avatar

Avatar

Aditya_S_

Avatar

Aditya_S_

Aditya_S_

23-01-2009

Is it included in any of the below licensed copies we have



1)Forms

2)Process Management

3)Reader Extensions

4)Output



Or, would it be an addtional license purchase ?



Thanks

Aditya
Highlighted

Avatar

Avatar

pguerett

Total Posts

7.7K

Likes

611

Correct Answer

692

Avatar

pguerett

Total Posts

7.7K

Likes

611

Correct Answer

692
pguerett

23-01-2009

No it is there ...look for the execute DDX under the foundation category. The DDX reference will be part of the docs.
Highlighted

Avatar

Avatar

yodadobe

Avatar

yodadobe

yodadobe

23-01-2009

I am using:

Category: Forms

Service Name: FormsService

Service Operation: processFormSubmission



The attachments come in off that as a list. I am then using the following script to move into a map for use in a later render:



import java.util.HashMap;

import java.util.List;

import java.util.Map;

import java.util.Iterator;

import com.adobe.idp.Document;



List attachmentList = patExecContext.getProcessDataListValue("/process_data/lsAttachments");



Map attachmentMap = new HashMap();



Iterator it = attachmentList.iterator();



while(it.hasNext()){

Document attDoc = (Document) it.next();

String name = (String) attDoc.getAttribute("name");

attachmentMap.put(name, attDoc);

}



patExecContext.setProcessDataMapValue("/process_data/attachments",attachmentMap);

attachmentList.clear();

patExecContext.setProcessDataListValue("/process_data/lsAttachments", attachmentList);
Highlighted

Avatar

Avatar

Aditya_S_

Avatar

Aditya_S_

Aditya_S_

23-01-2009

I can't seem to find execute DDX.



I only get:



Invoke DDX

Invoke DDX One Document



How does DDX work. Do you have a sample ?



Thanks

Aditya
Highlighted

Avatar

Avatar

pguerett

Total Posts

7.7K

Likes

611

Correct Answer

692

Avatar

pguerett

Total Posts

7.7K

Likes

611

Correct Answer

692
pguerett

23-01-2009

The suggestion that S Bishop has given you is an easier means.
Highlighted

Avatar

Avatar

Aditya_S_

Avatar

Aditya_S_

Aditya_S_

29-01-2009

S Bishop or Paul - Is it possible to view the attachment from the PDF as a form in Workspace ?



Aditya
Highlighted

Avatar

Avatar

pguerett

Total Posts

7.7K

Likes

611

Correct Answer

692

Avatar

pguerett

Total Posts

7.7K

Likes

611

Correct Answer

692
pguerett

29-01-2009

If you attach the attachments to the Task then you can view them.
Highlighted

Avatar

Avatar

Aditya_S_

Avatar

Aditya_S_

Aditya_S_

29-01-2009

I don't want to view the attachment from the attachment tab. I would like to view it in the form tab.



My situation - I have multiple contracts I want to upload for viewing only. these contracts will have their own instructions and other details. I have assigned variables and XPATH'd to the variables to dynamically change.



I would like to design a form which will allow users to attach one contract and enter values in Textfields. The textfields will map the values (via XSD) to the workbench variables and the attachment will be the form they will view in Workspace.



To implement the above scenario I need to display an attachment as a form in Workspace.



So my question would be, if I use the processFormSubmission extract the attachment, can I use the same variable as the input form variable in the task ?



Hope I was clear enough.