Skip to main content

Need help with Javamail

No replies
johniem
Offline
Joined: 2010-07-22

Hello,

I'm new to javamail and pretty much confused with some aspects of it.
Although i manage to send and receive simple text and html mails, I have problems
reading a blob image from mysql and then adding it to the mail message.

I've tried the

javax.mail.util.ByteArrayDataSource(inputStream,"image/jpeg")

but hte message is arriving as a binary string and not as an image.
I know that I'm doing something wrong here but some guidance will be really appreciated.

Thanks in advance.