Bug 45690

Summary: poi-3.5-beta1 ExtractorFactory.createExtractor doesn't work for .docm files
Product: POI Reporter: Khalid <kelma18>
Component: XWPFAssignee: POI Developers List <dev>
Status: RESOLVED FIXED    
Severity: normal    
Priority: P2    
Version: 3.5-dev   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Attachments: Common docm file (Word 2007 macro-enabled document) causes error described

Description Khalid 2008-08-26 01:57:35 UTC
ExtractorFactory.createExtractor(pkg) doesn't work for the macro-enabled Word (.docm) with mimetype: 
- "application/vnd.ms-word.document.macroEnabled.12"

Exception:
java.lang.IllegalArgumentException: No supported documents found in the OOXML package

It is not desperately necessary because with the XWPFWordExtractor class it works too. But it would be nice when this can be fixed.

Best regards,

Khalid
Comment 1 Nick Burch 2008-08-27 03:32:13 UTC
Any chance you could upload a sample .docm file?

We'll want that so we can write unit tests to ensure things work after the fix, and don't get broken again later on
Comment 2 Anton Chertov 2009-05-22 01:19:24 UTC
Created attachment 23706 [details]
Common docm file (Word 2007 macro-enabled document) causes error described
Comment 3 Anton Chertov 2009-05-22 01:21:21 UTC
The bug appears in apache-poi-3.5-beta5.
File that causes error is uploaded as an attachment.
Comment 4 Nick Burch 2009-11-03 17:36:17 UTC
I've just added a unit test for this, and it all passes just fine. I think this bug has already been fixed