Click here to Skip to main content
15,347,523 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I need to convert html content to word,all text display proper but image not render inside word document.

What I have tried:

For example :

<p>Taken from wikpedia</p>
<img src="data:image/png;base64, iVBORw0KGgoAAAANSUhEUgAAAAUA
9TXL0Y4OHwAAAABJRU5ErkJggg==" alt="Red dot" />
Updated 24-Jan-21 3:06am
OriginalGriff 7-Dec-18 1:48am
This is not a good question - we cannot work out from that little what you are trying to do.
Remember that we can't see your screen, access your HDD, or read your mind - we only get exactly what you type to work with. So show us the code you tried, and tell us exactly what it did that you didn't expect, or didn't do that you did!

Use the "Improve question" widget to edit your question and provide better information.

1 solution

It seems Word can not handle this kind of data: see answer here: How to display images in Word generated from HTML? - Stack Overflow[^]
But it might be possible with Office 365 Word 2016, see example here: Inserting a base64 encoded image into a Word 2016 document | xomino to 365[^]

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900