We're sorry GroupDocs doesn't work properply without JavaScript enabled.

Free Support Forum - groupdocs.com

XPS files identified as ZIP in parser API for .NET

Hello, we are experiencing issue that internal FileType definition list (in GroupDocs.Parser.Options namespace) does not content XPS FileType. At the same time when trying to parse XPS file it is identified as ZIP and parsed accordingly. The parsing itself work correctly, just the FileType identification is missing, leading to problems when needing to have separate processing for XPS and “ordinary” ZIP files.

Please add XPS to FileType list and return it in DocumentInfo when parsing XPS files.

Many thanks

@jvymazal

We are investigating this scenario. Your investigation ticket ID is PARSERNET-1836.

@jvymazal

We’ve an update on PARSERNET-1836.
FileType property of IDocumentInfo object provides a type of file format for which Parser object is created. In the case of XPS file format Parser object is created for ZIP container (XPS is actually a ZIP file) and provides only those features which are supported for containers (like files and images extraction). XPS file format isn’t supported at this time.

Thanks, I realize that XPS is actually a ZIP file and parser treats it as such; that is fine for our current use case. However I need some way to distinguish if the file is originally ZIP or XPS or OXPS based on IDocumentInfo object. Could you please add it to list so I can build my logic around that? Implementation-wise it is enough to just copy ZIP IDocumentInfo and set fileType to XPS/OXPS and return that object when parser is created for XPS/OXPS file.

Thanks

@jvymazal

We’ll further look into this scenario and notify you about the outcomes.