Results 1 to 2 of 2
Thread: error in reading mail contents
- 08-21-2008, 09:04 PM #1Member
- Join Date
- Aug 2008
- Rep Power
error in reading mail contents
I am developing java mail application.i want to read mail from java E-mail server(JES).i used the method getcontent() like this
System.out.println(message[i].getContent()); but i am geting the out put
"avax.mail.internet.MimeMultipart@b1cd0" which is not the mail content.i tried message[i].WriteTo(System.out); but it is giving me all the unecessary content like
messae-id,message version,content-type,encoding-type,contern decsription.
but i don't want them. i want only the body and the attached file.So
please help me how to read it.
- 08-22-2008, 01:14 AM #2the out put
Check the API doc for getContent() to see what it returns.
If it returns an object, you'll need to cast that object and you can then use its methods to get its contents.
- By namarc in forum Advanced JavaReplies: 2Last Post: 05-05-2008, 07:01 AM
- By Java Tip in forum Java TipReplies: 0Last Post: 02-07-2008, 10:00 AM
- By Mr tuition in forum AWT / SwingReplies: 1Last Post: 01-16-2008, 01:39 AM
- By javaplus in forum NetworkingReplies: 2Last Post: 11-29-2007, 11:28 AM
- By orchid in forum New To JavaReplies: 1Last Post: 04-22-2007, 03:34 AM