Showing posts with label Email Adapter. Show all posts
Showing posts with label Email Adapter. Show all posts

Thursday, January 8, 2015

#369 UMS Email adapter (part 2)--> send PDF file as an email attachment

Simple scenario -

Read in a pdf file and send it as a pdf attachment.









fileService_4 configuration -














































































The strategy I am using here, is not to read the contents, so I get the file and
directory names from the header. These I copy into process variables -


















This information will be used in a function to
add the file as an attachment to the email.

I will be using the ora:readFile function -
e.g. ora:readFile('file:///c:/docs/My.pdf'')

I need to swap the "\" to "/" in the directory variable.
I then create a variable with the value'file:///c:/docs/My.pdf''






I then set the attachment values on the EmailPDF activity as follows -








I deploy and test -

For testing purposes, I will drop the BAM pdf into the input directory.










The email arrives with the attachment -














I open the pdf -











#368 UMS Email adapter --> send file as an an attachment part 1

Simple Scenario -


























































Here is the Assign from the BPEL process -










Here is the SendEmail config -











































Deploy and test -

Here is my input file -




















My input directory is -



















Test - copy the myFile.txt to the input directory -

Check for the email -