How to display data uri scheme into a C# WebBrowser Controler

Posted by Emanuel on Stack Overflow See other posts from Stack Overflow or by Emanuel
Published on 2010-05-25T18:09:48Z Indexed on 2010/05/25 18:11 UTC
Read the original article Hit count: 291

Filed under:
|
|
|
|

How can I show an image base64 encoded using WebBrowser control in C#?

I used the following code:

<img src="data:image/gif;base64,/9j/4AAQSkZJRgABAgAAZABkAA7AAR
R894ADkFkb2JlAGTAAAAAAfbAIQABAMDAwMDBAMDBAYEAwQGBwUEBAUHCAYGBw
...
uhWkvoJfQO2z/rf4VpL6CX0Dts/63+FaS+gl9A7bP+tthWkvoJfQODCde4qfcg
RiNWK3UyUeX9CXpHU43diOK915X5fG/reux5hUAUBftZ" />

but no image is displayed. One solution would be to save images locally and using absolute path, but this is not desirable.

Any idea?

Thanks.

© Stack Overflow or respective owner

Related posts about c#

Related posts about data