Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Open generated Web Page with WebBrowser object in VB

I'd like to know if it possible to show HTML page created in VB using WebBrowser object without using files on disk. That is, create HTML file in memory and show it within WebBrowser object. Thanks!

like image 836
Costa Mirkin Avatar asked Oct 16 '11 10:10

Costa Mirkin


1 Answers

Using Visual Basic in .Net Framework...

webBrowser1.DocumentText = "<html><body><a href='http://www.mywebsite.com'>My Web Site</a></body></html>"

In old Visual Basic 6, try...

WebBrowser1.Document.Open
WebBrowser1.Document.Write "<html><body><a href='http://www.mywebsite.com'>My Web Site</a></body></html>"
WebBrowser1.Document.Close
like image 125
Adriano Silva Avatar answered Sep 30 '22 09:09

Adriano Silva