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.

Assemble PDF with attachments

Avatar

Former Community Member
Hi All,<br /><br />I am planning to assemble a PDF document with attachments. Or as I see my requirement is to create a PDF and attach various files to it. The PDF would then be sent as an attachment to an email.<br /><br />The user should be able to open the emailed PDF and save the image/application attachments seperately.<br /><br />To achieve this I had generated the sample DDX and tried it in a process, but no luck.<br /><br />All the source objects are avaialble int he assembler map object of documents with the correct key value.<br /><br /><?xml version="1.0" encoding="UTF-8"?><br /><DDX xmlns="http://ns.adobe.com/DDX/1.0/"><br /><PDF result="pdf2image_res.pdf"><br /><PDF source="pdf2image_res.pdf"><br /> <FileAttachments source="image-1.jpg" nameKey="image-1.jpg"><br /> <File filename="image-1.jpg"/><br /> </FileAttachments><br /> <FileAttachments source="image-2.jpg" nameKey="image-2.jpg"><br /> <File filename="image-2.jpg"/><br /> </FileAttachments><br /></PDF><br /></PDF><br /></DDX><br /><br />Then I extract the generated pdf in a document like '/process_data/docAssemblerMap[@id='pdf2image_res.pdf']'<br /><br />The generated PDF does not have the attachments embedded in it.<br /><br />Any thoughts/help would be greatly appreciated.
1 Reply

Avatar

Level 10
I tried it with your ddx (with minor modification)and it worked fine.



I would try to use the Record and Play back to make sure all the components of your map are set properly.



Jasmin