# [.net] AxSHDocVw.AxWebBrowser(SOLVED)

This topic is 4464 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

I'm trying to use the COM component web browser control AxSHDocVw.AxWebBrowser to display a web page on a windows form inside a tab on a tab control using VB.NET. Did that come out straight? I'm just using the gamedev page for testing, I'll later point to a page on our intranet. Anyway, here is the code:
Try
Dim webBrowser As New AxSHDocVw.AxWebBrowser
CType(webBrowser, System.ComponentModel.ISupportInitialize).BeginInit()
webBrowser.Enabled = True
CType(webBrowser, System.ComponentModel.ISupportInitialize).EndInit()
webBrowser.Dock = Dockstyle.Fill
webBrowser.Navigate2("http://www.gamedev.net", 0, 0, 0, 0)
webBrowser.Show()
Catch ex As Exception
MessageBox.Show(ex.ToString, "Crash and Burn", MessageBoxButtons.OK)
End Try

It doesn't crash anymore, but nothing shows up in the tab. I've gotten it to open up in a new IE window before, but just can't get it to go in the tab. Has anyone tried this before? EDIT: Nevermind, I figured it out. [Edited by - Wolfmanyoda on December 4, 2005 11:09:46 AM]