Free Support Forum - aspose.com

Incorrect text after converting to XPS

Aspose.Words v6.5.0.0

After converting attached DOCX file into XPS (attached too) we have incorrect Cyrillic text in table header and some symbols in empty FormField. If saving as XPS from Microsoft Word 2007 (SP2) we have correct document.

Hi <?xml:namespace prefix = st1 ns = "urn:schemas:contacts" />Alexander,

<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Thanks for your request. I cannot see any problems with Cyrillic text in the XPS document produced by Apsose.Words. Please see the attached screenshot. On left side is XPS produced by Aspose.Words and on the right side XPS produced by MS Word.

Regarding the problem with empty form fields, I linked your request to the appropriate issue. You will be notified as soon as it is resolved. As a workaround, you can just set an empty value of the form field. Here is the code:

//Open document

Document doc = new Document(@"Test075\in.doc");

//Before saving we should remove values from empty formafields

foreach (FormField field in doc.Range.FormFields)

{

if (string.IsNullOrEmpty(field.Result))

field.Result = string.Empty;

}

Hope this helps.

Best regards.

Thanks for workaround with null FormFields.

I attached screnshots for original DOCX document, saved as XPS by Aspose.Words and saved as XPS by Microsoft Word 2007 (SP2) from my side. I also attached saved XPS document from Word.

My current system locale format is Russian, locale for non-unicode - Russian.

System Locale: ru;Russian
Input Locale: en-us;English (United States)

P.S. I can't attach plain XPS without zipping it.

Hi <?xml:namespace prefix = st1 ns = "urn:schemas:contacts" />Alexander,

<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

What viewer do you use to open XPS documents? XPS document you have attached looks fine when I open it using IE7. So, most likely, your viewer does not like something in XPS document produced by Aspose.Words.

Best regards.

I checked XPS produced by Aspose.Words in IE8 on Windows Vista SP2 - font and text are correct. But in this viewer they broken.

I use english version of "Microsoft XML Paper Specification Essentials Pack" v1.0 (http://www.microsoft.com/downloads/details.aspx?displaylang=en&FamilyID=b8dcffdd-e3a5-44cc-8021-7649fd37ffee) on Windows Vista SP2 (EN).

<?xml:namespace prefix = st1 ns = "urn:schemas:contacts" />Alexander, thank you for additional information. I just installed this XPS viewer on my side and XPS document still looks fine. I tested on Won XP SP3 (en) and on Win 2003 (en). Maybe this is some kind of bug in XPS viewer EP for Vista.

<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Best regards.

Test on Vista please, because I posted real screenshots and it looks like same on second Vista machine. Can I help with additional information about OS, culture info?

P.S. You test "LS-Aspose-B25-Sample.xps", right?

<?xml:namespace prefix = st1 ns = "urn:schemas:contacts" />Alexander, I will ask our developers who use Vista to check this issue on their side. I will get back to you once we check the problem on Vista.

<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Yes, I used your XPS for testing. Could you please try opening the attached XPS document on your side? Does it look the same as XPS produced on your side?

Best regards.

Yes, it looks the same:

<?xml:namespace prefix = st1 ns = "urn:schemas:contacts" />Alexander, just tested your XPS on Vista and still it looks fine. Maybe we use different builds of XPS viewer. Can you download XPS viewer from the link you gave me and reinstall it?

<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Also, regarding culture. I do not think the issue is related to culture, because another Russian text is shown correctly. It seems, for some reason, your XPS viewer does not like subset of Calibri Bold font stored in XPS document.

Best regards.

I can reinstall later.

I create DOCX document with line TEST in Calibry Bold and convert to XPS by Aspose. This XPS document loks fine in IE8, but in my XPS Viewer I see empty clear page. Both document attached.

My XPS Viewer build in screenshot:

It is really odd problem. Because the same build of XPS Viewer EP is installed on my side and all your XPS documents looks fine on my side.

The issues you have found earlier (filed as 7770) have been fixed in this update.


This message was posted using Notification2Forum from Downloads module by aspose.notifier.
(55)