I want to make it so that when a user clicks on the first item which is "IP Address" to show Form2, I'm not sure if I'm using the SelectedItem correctly. I keep getting a "conversion from string to type double is not valid" error.Code:Imports System.Net Public Class Form1 Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load lstboxoption.Items.Add("IP Address") lstboxoption.Items.Add("Source Code") End Sub Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click If lstboxoption.SelectedItem = 0 Then Form2.Show() End If End Sub End Class




Reply With Quote
