简体   繁体   中英

HTML 'img' Tag do not operate in WebBrowser Control

Sorry for poor English. Image html tag do not operate and display Xbox in WebBrowser Control. C# Source)

webBrowser1.Navigate("about:blank");
webBrowser1.Document.OpenNew(false);
webBrowser1.Document.Write(str_html);
webBrowser1.Refresh();

HTML ex)

<html><head></head><body><img src="d:/report/1.bmp" width=1000></body></html>

xBox

Try assigning it to an object.

This is an example that I used and works:

webBrowser1.DocumentText = "<html><head></head><body><img src='C:/srcFolder/imagelocationURL.png'/></body></html>"

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM