I am reading eml file from local disk:
InputStream is = new FileInputStream(body_path);
MimeMessage message = new MimeMessage(session,is);
Multipart multipart = (Multipart)message.getContent();
Now how do i remove attachment of ".dat" type?
I am reading eml file from local disk:
InputStream is = new FileInputStream(body_path);
MimeMessage message = new MimeMessage(session,is);
Multipart multipart = (Multipart)message.getContent();
Now how do i remove attachment of ".dat" type?
You can do something like this :-
Compose a
new mimemsg
and add all parts one by one except the part with extensionDAT
Compose a new message :-