dcsimg
POP3 problems
3 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Andrew_Chua
Posted On:   Tuesday, December 4, 2001 10:46 PM

Is it possible to move messages in POP3 to a local folder using javamail? If so, how? And anoher thing is that, can anybody offer suggestions on figuring out which mails are already read in POP3?

Thanks!!!

Re: POP3 problems

Posted By:   Sharona_Feinberg  
Posted On:   Sunday, December 16, 2001 04:15 AM

you are right !
-it is a POP3 problem


the answer that you got is correct for IMAP4


POP3 does not support flags - therfore you can not distiguish between read/unread emails.


sorry.

Re: POP3 problems

Posted By:   John_Zukowski  
Posted On:   Monday, December 10, 2001 11:20 PM

Both of your questions are already answered in the FAQ.

LOOK At <font size=2><pre>setFlag(Flags.Flag.SEEN, true);</pre></font> and <font size=2><pre>if (!messages[i].isSet(Flags.Flag.SEEN))</pre></font>

Posted By:   James_Kelley  
Posted On:   Wednesday, December 5, 2001 06:20 PM


Something like this






// Get attributes & flags for all messages
Message[] messages = folder.getMessages();
FetchProfile fp = new FetchProfile();
//fp.add(FetchProfile.Item.ENVELOPE);
fp.add(FetchProfile.Item.FLAGS);
//fp.add("X-Mailer");
folder.fetch(messages, fp);



// Process each message
for (int i = 0; i < messages.length && i < 1500; i++)
{
if (!messages[i].isSet(Flags.Flag.SEEN))
{
//do something
}
messages[i].setFlag(Flags.Flag.SEEN, true);
}

folder.close(true);
popConn.store.close();
About | Sitemap | Contact