I am developing one win application which makes use of WebBrowser control.I am passing the url in a text box and the page is getting displayed in the web browser control.Till this its fine.Whn ever a link is clicked inside the webbrowser control it is opening in the same page.Is there any way such that the clicked links inside a webbrowser control should open in a new tab with the tab having the page title.
I tried the following code:
Expand|Select|Wrap|Line Numbers
- TabPage newPage = new TabPage("New Page");
- tabControl1.TabPages.Remove(newPage);
- WebBrowser wb = new WebBrowser();
- wb.Size = tabControl1.Size;
- wb.Navigate(webBrowser1.StatusText.ToString());
- TabPage tp = new TabPage();
- tp.Controls.Add(wb);
- tp.Tag = wb;
- tabControl1.TabPages.Add(tp);
But this is not working ...Anyone having any sugessions / ideas how this can be done ???
Thanks in advance
Bryan