Getting the sender name and email from a stored message
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Manal_Aboujtila
Posted On:   Friday, May 10, 2002 06:07 PM

Hello There, I am building a pop3 client, my program downloads the messages and stores them as Blob in the Oracle database as follow: ByteArrayOutputStream os=new ByteArrayOutputStream(); message.writeTo(os); byte[] b=os.toByteArray(); // storing b in a blob when i get it back i get it as follow: byte b[]=rs.getBytes(); InputStream in = new ByteArrayInputStream( b ) ; MimeMessage m = new MimeMessage( session , in ) ; My problem is if I try to get the sender by using message.getFrom();  befor storing it in the database it does work.    More>>

Hello There,




I am building a pop3 client, my program downloads the messages
and stores them as Blob in the Oracle database as follow:




ByteArrayOutputStream os=new ByteArrayOutputStream();


message.writeTo(os);


byte[] b=os.toByteArray();





// storing b in a blob




when i get it back i get it as follow:




byte b[]=rs.getBytes();


InputStream in = new ByteArrayInputStream( b ) ;


MimeMessage m = new MimeMessage( session , in ) ;




My problem is if I try to get the sender by using


message.getFrom();


 befor storing it in the database it does
work.



but when I try to get the sender after fetching the message
from the database


it doesn't work, and outputs " Ljavax.mail.internet.InternetAddress;@7d13b5"



Any Help?



Thank you in advance.



 

   <<Less

Re: Getting the sender name and email from a stored message

Posted By:   John_Zukowski  
Posted On:   Saturday, May 11, 2002 05:15 PM

It is an array.
About | Sitemap | Contact