Read latest thread mail using javamail

766 Views Asked by At

as we know that Conversation threading is a feature used by many email clients in which the software aids the user by visually grouping messages.

i build an email client application using javamail running on Android.Guide from this post, i have sucessfully to get unread message. This output is nested mail like converstation

  - A replay to B (latest message)
     - B reply to A
        - mail from A to B (first mail)

My problem is, i want to get only the latest message on this thread [A replay to B (latest message)]. How Should i do it??

1

There are 1 best solutions below

0
On

You're going to have to request enough envelope/header information to figure out which message that is, then you can fetch only the content for that message.