Free Support Forum - aspose.com

document.getPageCount() returns wrong value

Hi,
I’m using the getPageCount() function. It returns ‘2’ despite the document has only one page.
That makes problem when I want to save document to PDF, in the result file there is additional empty page. Is there any workaround fot this problem?
I’m attaching problematic document.

Thanks.

Hi

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

Thanks for your request. I managed to reproduce the problem on my side. Your request has been linked to the appropriate issue. You will be notified as soon as it is resolved.

The problem occurs because there is floating table in your document. At the moment, Aspose.Words does not support positioning of floating tables. As a workaround, you can set “Text wrapping” of your table to “None”.

Best regards,

That works.
Thank you very much for help.

Hi Andrey, I have a similar problem, I have a word document that has 1156 pages, when I use thegetPageCount() method it returns 1, so the document is previously created, I am wondering how can I get all the tables of the document to set the “Text wrapping” to “None” in each table of the document?

Thanks in advance

Hello,

Thank you for your request.
It seems to me that you have not quite exact same problem that is described above.
Could you please attach your original document to analyze.
Just please tell the product version you are using. Please try to upgrade to the latest 10.0.1, which you can download here: http://www.aspose.com/community/files/72/java-components/aspose.words-for-java/category1378.aspx

Regarding your second question. You can use the class DocumentVisitor to cycle through all the cells in all tables. And set the property CellFormat.setWrapText(false);

Thanks rumata, I’ve downloaded the last release of AsposeWords, all our problems transforming Word document to PDF seems to be solved in this release, we are requesting an upgrade of our license to test the full functionalities,

Thanks again,

Hello

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

It is perfect, that you already resolved the problem. Please let us know in case of any issues. We will be glad to help you.

Best regards,

The issues you have found earlier (filed as WORDSNET-1940) have been fixed in this .NET update and in this Java update.


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