poi-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nick Burch <nick.bu...@alfresco.com>
Subject Re: How to extract embedded documents from a .msg
Date Mon, 13 Jun 2011 14:06:17 GMT
On Mon, 13 Jun 2011, Ezequiel Foncubierta wrote:
> I'm using the MAPIMessage class to extract attachments from an email 
> message and have some troubles to extract embedded documents (E.g. a 
> message attached). I'm trying to go through DirectoryChunk, but I don't 
> find a way to extract them. Basically, I need to access to its filename, 
> raw data (InputStream?) and mimetype. Is it possible? How can I get 
> them?

First up, make sure you're using 3.8 beta 3 as there has been some work 
done on the code recently

On a MAPIMessage, call getAttachmentFiles() to get AttachmentChunks. On 
each attachment, use attachFileName / attachLongFileName to figure out if 
it's one you want. If it is, your data is in attachData


To unsubscribe, e-mail: user-unsubscribe@poi.apache.org
For additional commands, e-mail: user-help@poi.apache.org

View raw message