Why compressed xps are corrupt?
Posted
by Gio
on Stack Overflow
See other posts from Stack Overflow
or by Gio
Published on 2010-06-07T09:09:05Z
Indexed on
2010/06/07
9:12 UTC
Read the original article
Hit count: 302
compressed xps documents do not pass isxps.exe test and do not display in xpsviewer. i'm using Windows 7 and vs2010.
Dim ms = New MemoryStream()
Dim P As Package = Package.Open(ms, FileMode.Create, FileAccess.ReadWrite)
Dim DocumentUri As Uri = New Uri("pack://document.xps")
PackageStore.AddPackage(DocumentUri, P)
Dim document As XpsDocument = New XpsDocument(P, CompressionOption.Maximum, DocumentUri.AbsoluteUri)
If i change CompressionOption.Maximum to CompressionOption.None all works perfectly.
IsXps.exe says "Unable to open Zip archive Error code: 0x8000FFFF", same with default W7 XpsViewer.
what i'm doing wrong?
(i've also installed latest 7zip program, but i do not think that it may corrupt the default windows zip capability......or not?)
© Stack Overflow or respective owner