RSS

Must issue a STARTTLS command first” while sending email

11 May

When encountered this type of error when sending email with java mail feature, just set the below mentioned attribute to the Properties object you are using before,

Properties props = System.getProperties();

.

.

.

props.put(“mail.smtp.starttls.enable”,”true”);
 
Leave a comment

Posted by on May 11, 2011 in Java

 

Tags: , , ,

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: