İl & İlçe
Hangi İli Seçer İseniz O İlin İlçelerini Listeliyor...
Public Class Form1
Private Sub ComboBox1_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ComboBox1.SelectedIndexChanged
ComboBox2.Items.Clear()
If ComboBox1.Text = "Ankara" Then
ComboBox2.Items.Add("Çankaya")
ComboBox2.Items.Add("Etimesgut")
ComboBox2.Items.Add("Keçiören")
ComboBox2.Items.Add("Yenimahalle")
ComboBox2.Items.Add("Mamak")
ElseIf ComboBox1.Text = "İstanbul" Then
ComboBox2.Items.Add("Beşiktaş")
ComboBox2.Items.Add("Şişli")
ComboBox2.Items.Add("Eminönü")
ComboBox2.Items.Add("Beykoz")
ComboBox2.Items.Add("Adalar")
ElseIf ComboBox1.Text = "İzmir" Then
ComboBox2.Items.Add("Karşıyaka")
ComboBox2.Items.Add("Bornova")
ComboBox2.Items.Add("Güzelyalı")
ComboBox2.Items.Add("Buca")
ComboBox2.Items.Add("Konak")
End If
End Sub
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
End Sub
End Class
|