This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes Email attachment Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Email attachment" Watch "Email attachment" New topic
Author

Email attachment

Peter Phung
Ranch Hand

Joined: Dec 06, 2001
Posts: 138
Can anyone tell me how i can send a file as an email attachment?


Pete<br />"Reality is an illusion <br />brought on by a lack of <br />drink, drugs and smut"
Dirk Schreckmann
Sheriff

Joined: Dec 10, 2001
Posts: 7023
Do you mean using Java?


[How To Ask Good Questions] [JavaRanch FAQ Wiki] [JavaRanch Radio]
Peter Phung
Ranch Hand

Joined: Dec 06, 2001
Posts: 138
Yes. Is it possible?
Dirk Schreckmann
Sheriff

Joined: Dec 10, 2001
Posts: 7023
Do you already know how to send a plain text email message with some Java application?
Peter Phung
Ranch Hand

Joined: Dec 06, 2001
Posts: 138
I do kind of know how to do it, but not really. I've been using my predecessor's email class but i would like to write my own because i'd like to be able to send attachments.
Any help u can give me would be appreciated
Gregg Bolinger
GenRocket Founder
Ranch Hand

Joined: Jul 11, 2001
Posts: 15299
    
    6

You need to use the JavaMail API. Here is a link to a really good tutorial. It also shows how to send attatchments.
http://developer.java.sun.com/developer/onlineTraining/JavaMail/contents.html


GenRocket - Experts at Building Test Data
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Email attachment
 
Similar Threads
Reading a large file, getting out of memory error.
Java Mail attachment Scanning
including html in email
email attachment
Compatibility