Top "Jakarta-mail" questions

A Java API to send and receive emails.

Sending Email via gmail smtp server in JAVA

What is the problem with this code? Somehow it is getting in to an infinity loop at the line Transport.…

java smtp jakarta-mail
How to read text inside body of mail using javax.mail

i'm developing a client mail using javax.mail to read mail inside mail box: Properties properties = System.getProperties(); properties.setProperty("…

java mime multipart jakarta-mail
Sending mail error, javax.mail.MessagingException: Could not connect to SMTP host: localhost, port: 25;

Here is my code import java.util.Properties; import javax.mail.Message; import javax.mail.MessagingException; import javax.mail.Session; …

java netbeans jakarta-mail sendmail connectionexception
Inline images in email using JavaMail

I want to send an email with an inline image using javamail. I'm doing something like this. MimeMultipart content = new …

java mime mime-types jakarta-mail multipart
Unable to send an email using SMTP (Getting javax.mail.MessagingException: Could not convert socket to TLS;)

I have written the following code for sending email using javamail API through SMTP as TLS as SSL is not …

java ssl smtp jakarta-mail
JavaMail smtp properties (for STARTTLS)

JavaMail specifies a bunch of properties that can be set to configure an SMTP connection. To use STARTTLS it is …

java smtp jakarta-mail starttls
Download attachments using Java Mail

Now that I`ve downloaded all the messages, and store them to Message[] temp; How do I get the list …

java attachment jakarta-mail
JavaMail with Gmail: 535-5.7.1 Username and Password not accepted

I get this error when I try to send a mail using JavaMail API. I am sure that the username …

java jakarta-mail
Accessing emails from gmail using IMAP ( javamail API)

I am trying to access emails from Gmail accounts through IMAP with the help of the JavaMail API. I was …

java gmail imap jakarta-mail
how to send HTML email

I have to send HTML file via email but not as attachment. Message simpleMessage = new MimeMessage(mailSession); try { fromAddress = new …

html jakarta-mail