wood burning stoves 2.0*
The moose likes Other JSE/JEE APIs and the fly likes imap javamail help Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Java » Other JSE/JEE APIs
Bookmark "imap javamail help" Watch "imap javamail help" New topic
Author

imap javamail help

Jitesh Ranavaya
Greenhorn

Joined: Sep 09, 2004
Posts: 9
I decided it would be easier to use IMAP, since I'm only interested in sending emails. My test program is shown below, am pretty sure somethings wrong...I just dont know what. I get the following error:

java.net.ConnectException: Connection timed out: connect

Heres the code:


I'm in desperate need for this to work....somebody please help.
Jitesh Ranavaya
Greenhorn

Joined: Sep 09, 2004
Posts: 9
I think the line:

Store store = s.getStore("imap");

should read...

Store store = s.getStore("pop3");

but now I get these two errors at different times...

javax.servlet.ServletException: [IN-USE] account is locked by another session or for maintenance, try again.

and....

class javax.mail.MessagingException: Could not connect to SMTP host: localhost, port: 25;
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: imap javamail help