doc.zip (63.1 KB)
Hi, when i open the docx file(the attachment above) by using aspose.word for java and do nothing to it, then just save it to another docx file, but unfournately, the newly saved docx’s style is different with the original one(eg, line spacing and some others). please help!
Document document = new Document("/tmp/sdtdoc.docx");
document.save("/tmp/sdtdoc-copy.docx");
Thanks for your inquiry. Have you tried the latest version of Aspose.Words for Java i.e. 20.3 on your end? In case the problem still remains, please also ZIP and upload your output Word document and a screenshot showing the problematic area(s) in Aspose.Words generated DOCX file here for testing. We will then investigate the issue further on our end and provide you more information.
style-diff.zip (295.2 KB)
yes, even if the lastest version(eval version), the problem still the same. i’ve attached the generated docx file and two style diff pngs。
We have converted your “sdtdoc.docx” to DOCX format by using the licensed latest version of Aspose.Words for Java i.e. 20.3 and attached it here for your reference:
Do you still see the same problems in this output DOCX Word document?
What MS Word version are you viewing these files with? Or do you use OpenOffice Writer or any other editor?
Please also convert (Save As) “sdtdoc.docx” to PDF format and attach the PDF file here for our reference. Thanks for your cooperation.
We tested the scenarios and have managed to reproduce the same problems on our end. For the sake of corrections, we have logged the following issues in our issue tracking system.
WORDSNET-20158: Table moves to next page during open save a DOCX WORDSNET-20159: Vertical spacing between lines increases during open save a DOCX
We will further look into the details of these issues and will keep you updated on the status of corrections. We apologize for your inconvenience.
Regarding WORDSNET-20159, it is to update you that we have completed the analysis of this issue on our end. Please see the analysis details below:
It is a known issue with pPrDefaults element missing in document produced by WPS Office. MS Word displays such documents depending on version and in this case, you need to explicitly specify version using LoadOptions.MswVersion.
Also, before 20.2 release of Aspose.Words, we had Word2007 version as default, and starting from 20.2 Aspose.Words, it now uses Word2013 version by default. If you want to see document as shown in MS Word 2013 by default, then please upgrade Aspose.Words to some of the latest versions. Hope, this helps.
Cookie Notice
To provide you with the best experience, we use cookies for personalization, analytics, and ads. By using our site, you agree to our cookie policy.
Enables storage, such as cookies, related to analytics.
Sets consent for sending user data to Google for online advertising purposes.
Sets consent for personalized advertising.
Cookie Notice
To provide you with the best experience, we use cookies for personalization, analytics, and ads. By using our site, you agree to our cookie policy.
More info
Enables storage, such as cookies, related to analytics.
Enables storage, such as cookies, related to advertising.
Sets consent for sending user data to Google for online advertising purposes.
Sets consent for personalized advertising.
Cookie Notice
To provide you with the best experience, we use cookies for personalization, analytics, and ads. By using our site, you agree to our cookie policy.
More info
Enables storage, such as cookies, related to analytics.
Enables storage, such as cookies, related to advertising.
Sets consent for sending user data to Google for online advertising purposes.