Visual Basic - System.NullReferenceException!
I have written the code in Visual Basic, in which I am getting the 'System.NullReferenceException' in the line CType(TabControl1.SelectedTab.Controls.Item(0), WebBrowser).Navigate(ComboBox1.Text). I am giving my code below :
Private Sub ComboBox1_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles ComboBox1.KeyPress
e.KeyChar = vbCr
CType(TabControl1.SelectedTab.Controls.Item(0), WebBrowser).Navigate(ComboBox1.Text)
My.Settings.History.Add(ComboBox1.Text)
ComboBox1.Items.Add(ToolStripComboBox2.Text)
End Sub
Does someone know how to remove this NullReferenceException ?? Please help as soon as possible.!!
Last edited by Soumen; 16-01-2010 at 03:36 PM.
QTechnology Ultra-Quiet ATX PSU 460W I MSI K8N Neo4-F I AMD Opteron 144 CABNE0545 2.66Ghz I 2 x 512MB RAM I 380GB Maxtor SATAI Raid0 Hard Drive I 40GB Maxtor IDE Hard Drive I Nvidia GeForce 7900GTX I Win XP Home Service Pack 2 I Soundblaster Xtreme Fidelity Fatal1ty I Mercury Home Theater HT-4500
Bookmarks