Implementation of E-mail sending function using Java Mail API
Run the Main.java
file in the /src
.
You are required to fill in the following information:
-
Who would you like to send the email for?
- This is the
To
blank. (What you enter should be a legal e-mail address)
- This is the
-
What is your email address?
- This is the
From
blank. (What you enter should be a legal e-mail address)
- This is the
-
Please enter the password of your email.
- This is the authorization code of your e-mail. Please make sure that POP3/SMTP service has been enabled.
-
Do you want to send a copy to anyone else? Y/N
- This is the button to enable
CC
. If you want to enable CC, enterY
. Otherwise,N
.-
Please enter email addresses(split with ",")
- You are supposed to enter a list of e-mail addresses that you intend to CC to, splitting with ",".
-
- This is the button to enable
-
Do you want sent a copy blindly? Y/N
- This is the button to enable
BCC
. If you want to enable BCC, enterY
. Otherwise,N
.-
Please enter email addresses(split with ",")
- You are supposed to enter a list of e-mail addresses that you intend to BCC to, splitting with ",".
-
- This is the button to enable
-
What is your subject of the email?
- This is the
Subject
blank.
- This is the
-
Enter the content of your email.
- This is the
Content
blank.
- This is the
-
Do you want to add an attachment? Y/N
- This is the button to enable
attachment
. If you want to enable attachment,enterY
. Otherwise,N
.-
Please enter the absolute path of your file.
- You are supposed to enter the absolute path of your file on your computer (e.g.
C:\Users\Desktop
). Then you've done everything. Wait patiently until the mail has been sent.
- You are supposed to enter the absolute path of your file on your computer (e.g.
-
- This is the button to enable
This work is licensed under a Apache License. Sincerely welcome contribution.