Welcome to the Java Programming Forums

The professional, friendly Java community. 21,500 members and growing!

The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 2 of 2

Thread: Show error message in sending mail using Java Servlet

  1. #1
    Junior Member
    Join Date
    Jul 2014
    Thanked 0 Times in 0 Posts

    Post Show error message in sending mail using Java Servlet

    I want to send mail using java Servlet.But when i create mail server as below it shows an error message.
     Properties p = new Properties();
    		p.put("mail.smtp.host", "smtp.gmail.com");
    in 2nd line error message is shown.
    I also included activation.jar and mail.jar in the classpath.

  2. #2
    Super Moderator
    Join Date
    Jun 2013
    So. Maryland, USA
    My Mood
    Thanked 698 Times in 680 Posts

    Default Re: Show error message in sending mail using Java Servlet

    Welcome to the forum! Thanks for taking the time to learn how to post code correctly. If you haven't already, please read this topic to learn other useful info for new members.

    Thread moved.

Similar Threads

  1. Error sending email using javax.mail : SMTP can only send RFC822 messages
    By greraume in forum What's Wrong With My Code?
    Replies: 0
    Last Post: June 20th, 2014, 09:17 AM
  2. problem while sending email using org.apache.commons.mail.*
    By gurleen in forum Java Theory & Questions
    Replies: 2
    Last Post: September 10th, 2012, 11:21 AM
  3. Replies: 3
    Last Post: March 3rd, 2011, 02:17 PM
  4. an error message while runnung java
    By sravan_kumar343 in forum Java Theory & Questions
    Replies: 1
    Last Post: January 25th, 2010, 10:19 AM
  5. Sending and Receiving mail using J2ME without server
    By chals in forum Java ME (Mobile Edition)
    Replies: 5
    Last Post: June 2nd, 2009, 09:59 AM

Tags for this Thread