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

Free Support Forum - aspose.com

How to remove text box from document

              Aspose.Html.Converters.Converter.ConvertHTML(@"<span>Hello  World!!</span>", ".", new Aspose.Html.Saving.DocSaveOptions(), "C:\\Users\\user161\\Desktop\\abc.docx");

Here I have written single line code to convert HTML string to docx file but after successfully converting for all text it is coming text box Capture.PNG (73.7 KB)
How can I remove this text box? I want normal text without a text box

@Shital_diwate

We have logged an issue as HTMLNET-3185 in our issue tracking system for further investigation on this case. We will look into its details and keep you posted with the status of its correction. Please be patient and spare us some time.

We are sorry for the inconvenience.

@Shital_diwate

We have performed an initial investigation against the logged ticket. HTML documents can have a very complex structure, which could not be represented using simple DOCX text paragraphs. That is why we use “TextBox” elements which allow us to preserve document layout. We can implement a new type of layout that will use text paragraphs, but the original HTML document structure will be lost.

This will be a complex new feature, implementation of which can take around three - four-month. Will such a layout fit your needs? Please provide your feedback so that we can further proceed accordingly.

1 Like

Hi Asad,

Sorry for delay from our end.

Expectation is to get the HTML Body as per the formatting in the Document.
Is there any other way to get it done?

@Shital_diwate

Can you please share a sample HTML file in .zip format for our reference? We will perform testing at our end and address the case accordingly.

Sure. We will give it ASAP.

Sample.zip (173.4 KB)
In this zip file there is html file, converter doc file and 2 images
also you can refer this issue How to remove text box from document

@Shital_diwate

Thanks for sharing the details.

We have logged the sample files and your concerns under the earlier logged ticket and will let you know as soon as new feature in the API is implemented. Please give us some time.

We apologize for the inconvenience.

@Shital_diwate

Due to the limited functionality of the DOCX format, there is no other way to preserve complex documents layouts, except the usage of the “TextBox” elements. The provided DOCX file has a background rendering issue, which can be fixed, but all the other elements have the correct format and positioning.