Apache POI - HSMF

String filename = "message.msg";
MAPIMessage msg = new MAPIMessage(filename);

PrintWriter txtOut = new PrintWriter("ApacheMessage.txt");
txtOut.println("Email Body: " + msg.getTextBody());
txtOut.close();

Aspose.Email

MailMessage messageMSG 	= MailMessage.load("message.msg", MessageFormat.getMsg());

messageMSG.save("AsposeMessage.msg", MessageFormat.getMsg());
messageMSG.save("AsposeMessage.eml", MessageFormat.getEml());
messageMSG.save("AsposeMessage.emlx", MessageFormat.getEmlx());
messageMSG.save("AsposeMessage.mht", MessageFormat.getMht());

Download Source Code

For More Examples, Please Visit Aspose Docs

Last edited Jun 20, 2014 at 6:15 AM by shoaibkhan, version 1