Expand my Community achievements bar.

Retrieve attachment from a PDF

Avatar

Level 2

Hi

Anyone know how can I retrieve the attachments from a PDF during a process?

Thanks.

Ryan

3 Replies

Avatar

Level 10

iText is a Java based API used to manipulate PDF documents.

Using this API, you can extract attachments from within LiveCycle.

Nith

Avatar

Level 2

Thanks.

But I used the Service Operation 'processFormSubmission' to retrieve the list of attachments.

Set

Variable Name: 'CONTENT_TYPE'

Value: application/pdf

In the 'Additional Output' section, there is a output parameter 'Attachments' for us to set the List (document) variable.

Avatar

Former Community Member

you can also use executeScript DSC to write a code to extract attachments.

Make a process variable of type "list" and subtype "document".

And then use patExecContext.getProcessDataListValue() method to get all the attachments.

and if you need to extract file extension of that attachment then you can use "wsfilename" attribute.

Thanks,

Prashast