on 05-05-2009 8:22 AM
Hello Experts,
i am new to the PI and i am trying to implement a file to mail scenario. i am following Stefan Grube's blog (/people/stefan.grube/blog/2007/04/17/xi-mail-adapter-an-approach-for-sending-emails-with-attachment-with-help-of-java-mapping) to send email using JAVA Mapping. i am able to send email to one recepient and i want to send to multiple recepients. i have tried with semicolon between two email Ids and it is not working. Any thoughts or help in this regard will be highly appreciated.
public void execute(InputStream in, OutputStream out)
throws StreamTransformationException {
String mailSubject = "=?utf-8?Q?Auftragsbest=C3=A4tigung?=";
String mailSender = "\"My Address\"<my address>";
String mailReceiver = "\"Your Address\"<address1;address2>";
Thanks & Regards
- Siva.
String mailReceiver = "\"Your Address\"<address1;address2>";
I hope that in your actual java mapping you are using the below mentioned format in the blog:
String mailReceiver = "\"Your Address\"<your.address+at+company.com>";
check usage of lt / gt for < / >
An email id needs to be separated using a semicolon only:)
Regards,
Abhishek.
format getting changed:(
Edited by: abhishek salvi on May 5, 2009 1:24 PM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
try directly with,
String mailReceiver = "emailID1,emailD2";
use comma as separator
and then try with semicolons if commas dont work
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Shabarish,
Thanks for the reponse. i have tried as you mentioed but no luck.
When i tried option 1 (With comma) - there was no error but didn't receive any email.
When i tried option 2 (with semicolon) - gave below error.
failed to send mail: java.io.IOException: server not responding OK to RCPT TO; 501 5.5.4 Invalid Address
Thanks
- Siva
User | Count |
---|---|
101 | |
13 | |
13 | |
11 | |
11 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.