Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

About JAVA MAIL  RSS feed

 
CATS
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,
I am testing the JavaMail codes writing in JSP using Tomcat 1.4.1 for local test, and Using Windows 2000 professional platform , and one of the tasks that I should do is to send emails and receive the emails(reading emails from MS Outlook), but the problem that exists is as the following :
it get the following exception :
javax.mail.MessagingException: Could not connect to SMTP host: localhost, port: 25;
nested exception is:
java.net.ConnectException: Connection refused: no further information

If my compnay has a mail server for intranet, do i have to install a mail server on my local machine?

Note: I am using JavaMail 1.2 for connecting, sending, and receiving the emails from the MS Outlook.
THANKS IN ADVANCE!!
 
Andres Gonzalez
Ranch Hand
Posts: 1561
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
well.. are you allowed to use the SMTP server? I know you're under an intranet, but you might want to check with your SA if you have enough privileges.
[ June 14, 2003: Message edited by: Andres Gonzalez ]
 
Vijay Gopalakrishnan
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can use localhost as smtp server only if you have a SMTP server installed in your machine.
But to send mails you can use the smtp server of your company and no need to have your own.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!