private void AddNewTab()
{
//we are creating tabpage and webbrowser
TabPage newtab = new TabPage();
WebBrowser brower1 = new WebBrowser();
//tabpage is adding to tabcontrol, webbrowser is adding to tabpage
tabControl1.Controls.Add(newtab);
newtab.Controls.Add(brower1);
//properties of tabpage and webbrowser
newtab.Text = "Tab Page";
brower1.ScriptErrorsSuppressed = true;
brower1.Navigate("www.google.com");
brower1.Dock = DockStyle.Fill;
brower1.DocumentTitleChanged += new EventHandler(setTitle);
}
public void AddTab_Click(object sender, EventArgs e)
{
AddNewTab();
}