Click here to Skip to main content
15,895,011 members
Please Sign up or sign in to vote.
4.00/5 (2 votes)
See more:
how can i display only the plain text messages from my gmail inbox using javamail in my java program..

i tried the following coding in my jsp program to read subject and content of my mail..
C#
out.print(message[i].getSubject());

out.print(message[i].getContent());



but i received output as...
night msg javax.mail.internet.MimeMultipart@110860e
last javax.mail.internet.MimeMultipart@1635d96
hello javax.mail.internet.MimeMultipart@bc8ba5

how can i get exact content of my mail...
Posted
Updated 11-Feb-12 17:58pm
v2
Comments
Sergey Alexandrovich Kryukov 8-Feb-12 11:17am    
What do you want to do with non-plain ones? "Flattern" them? Why not showing HTML or RTF as well?
--SA

1 solution

once again:

Follow this link, READ and you will get what you want:

http://java.sun.com/developer/onlineTraining/JavaMail/contents.html[^]

And please use hmailServer as a test environment, as Gmail only allowes 1 request per 15 minutes for new messages. See your last question to learn more about hmailServer.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900