Generate HTML content and display it in a WebBrowser control in C#

// Start at home.When you click the Set Contents button, the program uses the following code to display the HTML code in the upper text box in the WebBrowser.
wbrDisplay.GoHome();
// Set the HTML contents.
private void btn_Click(object sender, EventArgs e)
{
HtmlDocument doc = wbrDisplay.Document;
doc.Body.InnerHtml = txtHtml.Text;
}


Comments