Saving doc as HTML resize the images

Hi,

I am triying to convert a word document file into a HTML document.

Like:

WordDocument sourceDocument = new WordDocument(file, FormatType.Automatic);
MemoryStream htmlStream = new MemoryStream();
sourceDocument.Save(htmlStream, FormatType.Html);
htmlStream.Position = 0;

var htmlContent = "";
using (StreamReader sr = new StreamReader(htmlStream))
{
    htmlContent = sr.ReadToEnd();
};

File.WriteAllText(destinationFile, htmlContent);

But when I open the HTML file, the images are smaller and not in the same position.

Regards,
Juan Antonio


3 Replies

RH Ramanan  Hariharasubramanian Syncfusion Team October 11, 2017 04:34 PM UTC

Hi Juan,

Thank you for contacting Syncfusion support.

We can reproduce the reported issue from our side. We have prepared a sample based on your requirement which can downloaded from the following link.

Sample link:
http://www.syncfusion.com/downloads/support/forum/133133/ze/WordToHTMlConversion1534915561

Kindly conform us whether you are facing the same issue in the sample from your side. If not, modify this sample to reproduce the issue and share us the issue reproducing sample along with input document which will be helpful for us to provide you a prompt solution at the earliest.

Please let us know if you have any concerns.

Regards,
Ramanan H



JU Juan October 12, 2017 08:38 AM UTC

Hi,

Yes, same issue, also if i put the image in the rigth always appear in the left.

Regards

Juan Antonio



RH Ramanan  Hariharasubramanian Syncfusion Team October 13, 2017 01:36 PM UTC

Hi Juan,

Thank you for your update.

A support incident to track the status of “Saving doc as HTML resize the images” has been created under your account. Please log on to our support website to check for further updates

https://www.syncfusion.com/account/login

Please let us know if you have any other questions.

Thanks,
Ramanan H


Loader.
Up arrow icon