Cheeers!

Sorry was the confusion,

I figured that yesterday,

Thanks for your reply

Daniel.E
----- Original Message -----
From: "Richard Yee" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, September 25, 2002 11:33 PM
Subject: Re: JavaMail Bcc Not Working For Me


> Daniel,
> Check out Greg Dunn's email. I tried your code and it seems to work fine
> for me. The person in the TO field doesn't see the addresses in the BCC
> field. The people in the BCC field can see the address in the TO field but
> not other addresses in the BCC field. That is how it's supposed to work.
If
> you don't want anyone to know who the mail is sent TO, just put the same
> address in the TO field as in the FROM field and then include the original
> TO addressee in the BCC field. Got it?
>
> -Richard
>
>
>
> At 04:00 PM 9/25/2002 +0700, you wrote:
> >Hi Richard
> >
> >Cheers, I tried and still I can see the (to addresses) in the bcc email,
> >
> >I even tried this simple email  below and still I can see the to
addresses
> >in the Bcc Email .. Any work around for this?
> >
> >Thank you..
>
>/**************************************************************************
*
> >**************************/
> >Properties props = System.getProperties();
> >
> >    // Setup mail server
> >    props.put("mail.smtp.host", smtpHost);
> >
> >    // Get session
> >    Session sessionI = Session.getDefaultInstance(props, null);
> >
> >
> >
> >    // Define message
> >    MimeMessage message = new MimeMessage(sessionI);
> >
> >    message.setFrom(new InternetAddress(from));
> >    message.addRecipient(Message.RecipientType.TO,
> >      new InternetAddress(to));
> >     message.addRecipient(Message.RecipientType.BCC,
> >      new InternetAddress(bcc));
> >
> >    message.setSubject("Hi");
> >    message.setText("Mail test");
> >
> >    // Send message
> >   Transport.send(message);
> >
> >
> >/**************************************************************/
> >----- Original Message -----
> >From: "Richard Yee" <[EMAIL PROTECTED]>
> >To: <[EMAIL PROTECTED]>
> >Sent: Wednesday, September 25, 2002 2:57 PM
> >Subject: Re: JavaMail Bcc Not Working For Me
> >
> >
> > > Daniel,
> > > Check your code again. It looks like you are taking a list of
recipients
> > > delimited by ';' and ',', parsing it into separate tokens, converting
the
> > > individual addresses into Address[] and then using
> > > MimeMessage.addReceipients to add the individual addresses. You should
> > > either remove the loop and add all of the addresses at once using:
> > >
> > >       if (bcc != null) {
> > >              Address[] bccaddress = InternetAddress.parse(bcc);
> > >             msg.addRecipients(Message.RecipientType.BCC, bccaddress);
> > >       }
> > >
> > > or
> > >
> > >        if (bcc != null) {
> > >          strTokbcc = new StringTokenizer(bcc,";,");
> > >          while(strTokbcc.hasMoreTokens()) {
> > >             String strbcc = (strTokbcc.nextToken());
> > >             Address bccaddress = new InternetAddress(strbcc);
> > >             msg.addRecipient(Message.RecipientType.BCC, bccaddress);
> > >          }
> > >        }
> > >
> > > Regards,
> > >
> > > Richard
> > >
> > >
> > > At 09:53 AM 9/25/2002 +0700, you wrote:
> > > >Hi
> > > >
> > > >
> > > >//Set the BCC address of the Recipients
> > > >       if (bcc != null) {
> > > >         strTokbcc = new StringTokenizer(bcc,";,");
> > > >           while(strTokbcc.hasMoreTokens()) {
> > > >            String strbcc = (strTokbcc.nextToken());
> > > >             Address[] bccaddress = InternetAddress.parse(strbcc);
> > > >           msg.addRecipients(Message.RecipientType.BCC, bccaddress);
> > > >           }
> > > >       }
> > > >
> > > >I use this peice of code to send bcc for multiple bcc addresses in my
my
> > > >mail application, But if I send I am able to
> > > >see the To information in the bcc address, which should not be seen,
> > > >
> > > >Can you tell me where I am wrong?
> > > >
> > > >Thanks in advance!
> > > >
> > > >Daniel.E
> > > >
> > >
> >
>===========================================================================
> > > >To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
> > > >JSP-INTEREST".
> > > >For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
> >DIGEST".
> > > >Some relevant FAQs on JSP/Servlets can be found at:
> > > >
> > > >  http://archives.java.sun.com/jsp-interest.html
> > > >  http://java.sun.com/products/jsp/faq.html
> > > >  http://www.esperanto.org.nz/jsp/jspfaq.jsp
> > > >  http://www.jguru.com/faq/index.jsp
> > > >  http://www.jspinsider.com
> > >
> > >
>
>===========================================================================
> > > To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
> >JSP-INTEREST".
> > > For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
> >DIGEST".
> > > Some relevant FAQs on JSP/Servlets can be found at:
> > >
> > >  http://archives.java.sun.com/jsp-interest.html
> > >  http://java.sun.com/products/jsp/faq.html
> > >  http://www.esperanto.org.nz/jsp/jspfaq.jsp
> > >  http://www.jguru.com/faq/index.jsp
> > >  http://www.jspinsider.com
> >
>
>===========================================================================
> >To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
> >JSP-INTEREST".
> >For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
DIGEST".
> >Some relevant FAQs on JSP/Servlets can be found at:
> >
> >  http://archives.java.sun.com/jsp-interest.html
> >  http://java.sun.com/products/jsp/faq.html
> >  http://www.esperanto.org.nz/jsp/jspfaq.jsp
> >  http://www.jguru.com/faq/index.jsp
> >  http://www.jspinsider.com
>
>
===========================================================================
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
> For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
DIGEST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
>  http://archives.java.sun.com/jsp-interest.html
>  http://java.sun.com/products/jsp/faq.html
>  http://www.esperanto.org.nz/jsp/jspfaq.jsp
>  http://www.jguru.com/faq/index.jsp
>  http://www.jspinsider.com

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://archives.java.sun.com/jsp-interest.html
 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.jsp
 http://www.jguru.com/faq/index.jsp
 http://www.jspinsider.com

Reply via email to