On the forms Load event you need to set combo boxes 2,3 and 4 to visible=False. Then on the ComboBox1_SelectedIndexChanged event you can change combobox2 to visible=True and then do the same for each progression. The code is shown below. You will also need to decide how you want to reset previous box. In other words do you want to comboboxes 2, 3, and 4 to once again become invisible if you change from Motorbikes to none in combobox1?
Public Class Form1
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
ComboBox2.Visible = False
ComboBox3.Visible = False
ComboBox4.Visible = False
End Sub
Private Sub ComboBox1_SelectedIndexChanged(sender As Object, e As EventArgs) Handles ComboBox1.SelectedIndexChanged
If ComboBox1.SelectedItem="None" then
ComboBox2.Visible=False
ComboBox3.Visible=False
ComboBox4.Visible=False
Else
ComboBox2.Visible = True
End If
End Sub
Private Sub ComboBox2_SelectedIndexChanged(sender As Object, e As EventArgs) Handles ComboBox1.SelectedIndexChanged
ComboBox3.Visible = True
End Sub
Private Sub ComboBox3_SelectedIndexChanged(sender As Object, e As EventArgs) Handles ComboBox1.SelectedIndexChanged
ComboBox4.Visible = True
End Sub
End Class
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…