Free Support Forum -

Textbox text is lost after DOC to HTML conversion using Java


We are using aspose words Java 11.4 for converting word document to html.
We found that the text inside the shape is not visible in html. Please refer attached documents.

Do we need to set any Shape/TextBox property for making it visible?


Here the image is exported by aspose for the textbox containing the text which is not visible. The text font color is black in the word document but in the exported image the text font color is white. Hence even though it is present in html , it is not visible. The exported image is attached.
Please let us know solution for 11.4.

Hi Sonali,

Thanks for your query. I have managed to reproduce the same issue at my side. I have logged this issue as WORDSNET-6791 in our issue tracking system. I have linked this forum thread to the same issue and you will be notified via this forum thread once this issue is resolved.

Please use the following workaround for this issue:

Document doc = new Document(MyDir + "in.doc");

Shape shape = (Shape)doc.GetChild(NodeType.Shape, 0, true);

foreach ( Run run in ((Paragraph)shape.NextPreOrder(doc)).Runs)


run.Font.Color = Color.Black;


doc.Save(MyDir + "AsposeOut.html");

We apologize for your inconvenience.

Thanks Tahir. Setting Run node color again explicitly helped in solving the issue. As we have many large documents with many shape objects ,checking and modifying each run adds up to processing time. So it will be better if the WORDSNET-6791 get fix and we can avoid that extra processing. Is this fixed yet?Please update on this.


Hi Sonali,

Thanks for your inquiry. Could you please download the latest version of Aspose.Words ( v11.9.0 ) from the following link and let us know how it goes on your side?

I hope, this helps and thanks for your cooperation.