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

Free Support Forum - aspose.com

Convert Nested Table Absolute Width to Relative Width using Java Code | Set Table Width in Word DOCX Document

Hello,
Is there an easy way to convert table width to relative ?

I managed to do for table with absolute width => `100* tableWidth/pageWidth
For nested tables it is harder since I don’t have access to the parent width
Also for tables with AUTO width, I don’t have any clue about the absolute size so I cannot convert it

I don’t know if it is something possible or not and if yes how we could achieve it ?

@mohamed_hamdi,

Please ZIP and attach the following resources here for testing:

  • Your simplified input Word document
  • Aspose.Words for Java 20.9 generated output DOCX file showing the undesired behavior (if any)
  • Your expected DOCX file showing the desired output. You can create this document by using MS Word. Please also list the complete steps that you performed in MS Word to create the expected document on your end

As soon as you get these pieces of information ready, we will start investigation into your particular scenario/issue and provide you code to achieve the same by using Aspose.Words for Java.