begin process at 2012 02 16 00:32:43
  Trouver un code source :
 
dans
 
Accueil > 

Code

 > 

Jeux

 > DÉPARTEMENTS

DÉPARTEMENTS


 Information sur la source

Note :
Aucune note
Catégorie :Jeux Source .NET ( DotNet ) Classé sous :jeux, départements, array, VBAExcel, combobox Niveau :Débutant Date de création :19/09/2007 Date de mise à jour :02/04/2008 18:46:16 Vu / téléchargé :7 204 / 66

Auteur : Le Pivert

Ecrire un message privé
Commentaire sur cette source (10)
Ajouter un commentaire et/ou une note

 Description

C'est un jeu: vous situez le département correctement et vous avez le chef-lieu (c'est un de mes premiers programmes fait avec l'exemple de VB2005 Array)Amusez-vous.
J'ai ajouté le zip en VBA Excel pour les amateurs avec en plus les chefs-lieux.

Source

  • Public Class Form1
  • 'Donne le département en fonction du N°
  • Private Sub btndept_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btndept.Click
  • 'Pour empêcher un bug si l'on clique sans faire de saisie
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = (" Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background) 'Mettre le fichier wav dans le dossier 'Debug'
  • Else
  • On Error Resume Next
  • 'Methode Array pris dans les exemples de VB 2005, on appelle un nom avec un numéro
  • Dim Departement() As String = {"Numéro du Département", "L'Ain", "L'Aisne", "L'Allier", _
  • "Les Alpes-de-Hte-Provence", "Les Hautes-Alpes", "Les Alpes-Maritimes", "L'Ardèche", _
  • "Les Ardennes", "L'Ariège", "L'Aube", "L'Aude", "L'Aveyron", _
  • "Les Bouches-du-Rhône", "Le Calvados", "Le Cantal", "La Charente", _
  • "La Charente-Maritime", "Le Cher", "La Corrèze", "La Corse", "La Côte-d'Or", _
  • "Les Côtes-d'Armor", "La Creuse", "La Dordogne", "Le Doubs", "La Drôme", "L'Eure", "L'Eure-et-Loir", "Le Finistère", "Le Gard", _
  • "La Haute-Garonne", "Le Gers", "La Gironde", "L'Hérault", "L'Ille-et-Vilaine", "L'Indre", "L'Indre-et-Loire", "L'Isère", "Le Jura", _
  • "Les Landes", "Le Loir-et-Cher", "La Loire", "La Haute-Loire", "La Loire-Atlantique", "Le Loiret", "Le Lot", "Le Lot-et-Garonne", "La Lozère", _
  • "Le Maine-et-Loire", "La Manche", "La Marne", "La Haute-Marne", "La Mayenne", "La Meurthe-et-Moselle", "La Meuse", "Le Morbihan", "La Moselle", _
  • "La Nièvre", "Le Nord", "L'Oise", "L'Orne", "Le Pas-de-Calais", "Le Puy-de-Dôme", "Les Pyrénées-Alantiques", "Les Hautes-Pyrénées", "Les Pyrénées-Orientales", _
  • "Le Bas-Rhin", "Le Haut-Rhin", "Le Rhône", "la Haute-Saône", "La Saône-et-Loire", "La Sarthe", "La Savoie", "La Haute-Savoie", "La Seine", _
  • "La Seine-Maritime", "La Seine-et-Marne", "Les Yvelines", "Les Deux-Sèvres", "La Somme", "Le Tarn", "Le Tarn-et-Garonne", "Le Var", "Le Vaucluse", _
  • "La Vendée", "La Vienne", "La Haute-Vienne", "Les Vosges", "L'Yonne", "Le Territoire-de-Belfort", "L'Essonne", "Les Hauts-de-Seine", "La Seine-Saint-Denis", _
  • "Le Val-de-Marne", "Le Val-d'Oise"}
  • Dim i As Integer = CInt(TextBox1.Text)
  • TextBox2.Text = (Departement(i) & " est le bonne réponse.")
  • My.Computer.Audio.Play(Application.StartupPath & "\chimes.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • 'Réinitialiser
  • Private Sub btnreset_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnreset.Click
  • Dim aNumber As String = ""
  • TextBox1.Text = ""
  • TextBox2.Text = ""
  • End Sub
  • 'On cherche le département pour avoir le chef-lieu
  • Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = (" Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • 'Vous attribuez un bouton à un département
  • ElseIf TextBox1.Text = "01" Then
  • TextBox2.Text = (" Bourg en Bresse est le chef lieu du " & TextBox1.Text)
  • 'On met une musique associée à la réponse
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • aNumber &= ""
  • TextBox2.Text = (" Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "02" Then
  • aNumber &= ""
  • TextBox2.Text = (" Laon est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = (" Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "03" Then
  • TextBox2.Text = (" Moulins est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "04" Then
  • TextBox2.Text = (" Digne les Bains est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button6.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "05" Then
  • TextBox2.Text = (" Gap est le chef lieu du est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button7_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button7.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "06" Then
  • TextBox2.Text = (" Nice est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button8_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button8.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "07" Then
  • TextBox2.Text = (" Privas est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button9_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button9.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "08" Then
  • TextBox2.Text = ("Charleville-Mézières est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button10_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button10.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "09" Then
  • TextBox2.Text = (" Foix est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button11_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button11.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "10" Then
  • TextBox2.Text = (" Troyes est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button12_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button12.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "11" Then
  • TextBox2.Text = (" Carcassonne est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button13_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button13.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "12" Then
  • TextBox2.Text = (" Rodez est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button14_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button14.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "13" Then
  • TextBox2.Text = (" Marseille est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button15_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button15.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "14" Then
  • TextBox2.Text = (" Caen est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button16_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button16.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "15" Then
  • TextBox2.Text = (" Aurillac est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button17_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button17.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "16" Then
  • TextBox2.Text = (" Angoulême est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button18_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button18.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "17" Then
  • TextBox2.Text = (" La Rochelle est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button19_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button19.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "18" Then
  • TextBox2.Text = (" Bourges est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button20_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button20.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "19" Then
  • TextBox2.Text = (" Tulle est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button21_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button21.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "20" Then
  • TextBox2.Text = (" Ajaccio et Bastia sont les chefs lieux du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button22_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button22.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "21" Then
  • TextBox2.Text = (" Dijon est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button23_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button23.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "22" Then
  • TextBox2.Text = (" St Brieuc est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button24_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button24.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "23" Then
  • TextBox2.Text = (" Gueret est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button25_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button25.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "24" Then
  • TextBox2.Text = (" Périgueux est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button26_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button26.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "25" Then
  • TextBox2.Text = (" Besançon est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button27_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button27.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "26" Then
  • TextBox2.Text = (" Valence est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button28_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button28.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "27" Then
  • TextBox2.Text = (" Evreux est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button29_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button29.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "28" Then
  • TextBox2.Text = (" Chartres est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button30_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button30.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "29" Then
  • TextBox2.Text = (" Quimper est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button31_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button31.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "30" Then
  • TextBox2.Text = (" Nîmes est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button32_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button32.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "31" Then
  • TextBox2.Text = (" Toulouse est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button33_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button33.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "32" Then
  • TextBox2.Text = (" Auch est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button34_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button34.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "33" Then
  • TextBox2.Text = (" Bordeaux est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button35_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button35.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "34" Then
  • TextBox2.Text = (" Montpellier est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button36_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button36.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "35" Then
  • TextBox2.Text = (" Rennes est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button37_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button37.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "36" Then
  • TextBox2.Text = (" Chateauroux est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button38_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button38.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "37" Then
  • TextBox2.Text = (" Tours est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button39_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button39.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "38" Then
  • TextBox2.Text = (" Grenoble est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button40_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button40.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "39" Then
  • TextBox2.Text = (" Lons-le-Saunier est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button41_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button41.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "40" Then
  • TextBox2.Text = (" Mont-de-Marsan est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button42_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button42.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "41" Then
  • TextBox2.Text = (" Blois est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button43_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button43.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "42" Then
  • TextBox2.Text = (" St Etienne est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button44_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button44.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "43" Then
  • TextBox2.Text = (" Le Puy-en-Velay est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button45_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button45.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "44" Then
  • TextBox2.Text = (" Nantes est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button46_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button46.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "45" Then
  • TextBox2.Text = (" Orléans est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button47_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button47.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "46" Then
  • TextBox2.Text = (" Cahors est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button48_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button48.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "47" Then
  • TextBox2.Text = (" Agen est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button49_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button49.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "48" Then
  • TextBox2.Text = (" Mende est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button50_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button50.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "49" Then
  • TextBox2.Text = (" Angers est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button51_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button51.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "50" Then
  • TextBox2.Text = (" St Lô est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button52_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button52.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "51" Then
  • TextBox2.Text = (" Châlons-en Marne est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button53_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button53.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "52" Then
  • TextBox2.Text = (" Chaumont est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button54_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button54.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "53" Then
  • TextBox2.Text = (" Laval est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button55_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button55.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "54" Then
  • TextBox2.Text = (" Nancy est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button56_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button56.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "55" Then
  • TextBox2.Text = (" Bar-le-Duc est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button57_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button57.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "56" Then
  • TextBox2.Text = (" Vannes est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button58_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button58.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "57" Then
  • TextBox2.Text = (" Metz est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button59_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button59.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "58" Then
  • TextBox2.Text = (" Nevers est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button60_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button60.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "59" Then
  • TextBox2.Text = (" Lille est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button61_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button61.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "60" Then
  • TextBox2.Text = (" Beauvais est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button62_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button62.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "61" Then
  • TextBox2.Text = (" Alençon est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button63_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button63.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "62" Then
  • TextBox2.Text = (" Arras est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button64_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button64.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "63" Then
  • TextBox2.Text = (" Clermont Ferrand est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button65_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button65.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "64" Then
  • TextBox2.Text = (" Pau est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button66_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button66.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "65" Then
  • TextBox2.Text = (" Tarbes est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button67_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button67.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "66" Then
  • TextBox2.Text = (" Perpignan est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button68_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button68.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "67" Then
  • TextBox2.Text = (" Strasbourg est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button69_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button69.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "68" Then
  • TextBox2.Text = (" Colmar est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button70_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button70.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "69" Then
  • TextBox2.Text = (" Lyon est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button71_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button71.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "70" Then
  • TextBox2.Text = (" Vesoul est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button72_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button72.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "71" Then
  • TextBox2.Text = (" Mâcon est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button73_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button73.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "72" Then
  • TextBox2.Text = (" Le Mans est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button74_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button74.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "73" Then
  • TextBox2.Text = (" Chambéry est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button75_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button75.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "74" Then
  • TextBox2.Text = (" Annecy est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button76_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button76.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "75" Then
  • TextBox2.Text = (" Paris est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button77_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button77.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "76" Then
  • TextBox2.Text = (" Rouen est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button78_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button78.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "77" Then
  • TextBox2.Text = (" Melun est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button79_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button79.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "78" Then
  • TextBox2.Text = (" Versailles est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button80_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button80.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "79" Then
  • TextBox2.Text = (" Niort est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button81_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button81.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "80" Then
  • TextBox2.Text = (" Amiens est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button82_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button82.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "81" Then
  • TextBox2.Text = (" Albi est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button83_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button83.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "82" Then
  • TextBox2.Text = (" Montauban est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button84_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button84.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "83" Then
  • TextBox2.Text = (" Toulon est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button85_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button85.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "84" Then
  • TextBox2.Text = (" Avignon est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button86_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button86.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "85" Then
  • TextBox2.Text = (" La Roche sur Yon est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button87_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button87.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "86" Then
  • TextBox2.Text = (" Poitiers est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button88_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button88.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "87" Then
  • TextBox2.Text = (" Limoges est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button89_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button89.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "88" Then
  • TextBox2.Text = (" Epinal est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button90_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button90.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "89" Then
  • TextBox2.Text = (" Auxerre est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button91_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button91.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "90" Then
  • TextBox2.Text = (" Belfort est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button92_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button92.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "91" Then
  • TextBox2.Text = (" Evry est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button93_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button93.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "92" Then
  • TextBox2.Text = (" Nanterre est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button94_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button94.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "93" Then
  • TextBox2.Text = (" Bobigny est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button95_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button95.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "94" Then
  • TextBox2.Text = (" Créteil est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • Private Sub Button96_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button96.Click
  • Dim aNumber As String = ""
  • If TextBox1.Text = "" Then
  • TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • ElseIf TextBox1.Text = "95" Then
  • TextBox2.Text = (" Pontoise est le chef lieu du " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
  • Else : TextBox1.Text = TextBox1.Text
  • TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
  • My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
  • End If
  • End Sub
  • 'On quitte en demandant une réponse
  • Private Sub btnquit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnquit.Click
  • Dim answer As MsgBoxResult
  • answer = MsgBox("Voulez-vous quitter le jeu maintenant?", MsgBoxStyle.YesNo)
  • If answer = MsgBoxResult.Yes Then
  • MsgBox("Jeu terminé")
  • End
  • End If
  • End Sub
  • End Class
Public Class Form1
    'Donne le département en fonction du N°
    Private Sub btndept_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btndept.Click
        'Pour empêcher un bug si l'on clique sans faire de saisie
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = (" Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background) 'Mettre le fichier wav dans le dossier 'Debug'
        Else
            On Error Resume Next
            'Methode Array pris dans les exemples de VB 2005, on appelle un nom avec un numéro
            Dim Departement() As String = {"Numéro du Département", "L'Ain", "L'Aisne", "L'Allier", _
                          "Les Alpes-de-Hte-Provence", "Les Hautes-Alpes", "Les Alpes-Maritimes", "L'Ardèche", _
                          "Les Ardennes", "L'Ariège", "L'Aube", "L'Aude", "L'Aveyron", _
                          "Les Bouches-du-Rhône", "Le Calvados", "Le Cantal", "La Charente", _
                          "La Charente-Maritime", "Le Cher", "La Corrèze", "La Corse", "La Côte-d'Or", _
                          "Les Côtes-d'Armor", "La Creuse", "La Dordogne", "Le Doubs", "La Drôme", "L'Eure", "L'Eure-et-Loir", "Le Finistère", "Le Gard", _
                          "La Haute-Garonne", "Le Gers", "La Gironde", "L'Hérault", "L'Ille-et-Vilaine", "L'Indre", "L'Indre-et-Loire", "L'Isère", "Le Jura", _
                          "Les Landes", "Le Loir-et-Cher", "La Loire", "La Haute-Loire", "La Loire-Atlantique", "Le Loiret", "Le Lot", "Le Lot-et-Garonne", "La Lozère", _
                          "Le Maine-et-Loire", "La Manche", "La Marne", "La Haute-Marne", "La Mayenne", "La Meurthe-et-Moselle", "La Meuse", "Le Morbihan", "La Moselle", _
                          "La Nièvre", "Le Nord", "L'Oise", "L'Orne", "Le Pas-de-Calais", "Le Puy-de-Dôme", "Les Pyrénées-Alantiques", "Les Hautes-Pyrénées", "Les Pyrénées-Orientales", _
                          "Le Bas-Rhin", "Le Haut-Rhin", "Le Rhône", "la Haute-Saône", "La Saône-et-Loire", "La Sarthe", "La Savoie", "La Haute-Savoie", "La Seine", _
                          "La Seine-Maritime", "La Seine-et-Marne", "Les Yvelines", "Les Deux-Sèvres", "La Somme", "Le Tarn", "Le Tarn-et-Garonne", "Le Var", "Le Vaucluse", _
                          "La Vendée", "La Vienne", "La Haute-Vienne", "Les Vosges", "L'Yonne", "Le Territoire-de-Belfort", "L'Essonne", "Les Hauts-de-Seine", "La Seine-Saint-Denis", _
                          "Le Val-de-Marne", "Le Val-d'Oise"}
            Dim i As Integer = CInt(TextBox1.Text)
            TextBox2.Text = (Departement(i) & " est le bonne réponse.")
            My.Computer.Audio.Play(Application.StartupPath & "\chimes.wav", AudioPlayMode.Background)
        End If
    End Sub
    'Réinitialiser
    Private Sub btnreset_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnreset.Click
        Dim aNumber As String = ""
        TextBox1.Text = ""
        TextBox2.Text = ""
    End Sub
    'On cherche le département pour avoir le chef-lieu
    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = (" Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
            'Vous attribuez un bouton à un département
        ElseIf TextBox1.Text = "01" Then
            TextBox2.Text = (" Bourg en Bresse est le chef lieu du " & TextBox1.Text)
            'On met une musique associée à la réponse
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            aNumber &= ""
            TextBox2.Text = (" Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "02" Then
            aNumber &= ""
            TextBox2.Text = (" Laon est le chef lieu du " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = (" Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "03" Then
            TextBox2.Text = (" Moulins est le chef lieu du " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "04" Then
            TextBox2.Text = (" Digne les Bains est le chef lieu du " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button6.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "05" Then
            TextBox2.Text = (" Gap est le chef lieu du est le chef lieu du " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button7_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button7.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "06" Then
            TextBox2.Text = (" Nice est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button8_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button8.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "07" Then
            TextBox2.Text = (" Privas est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button9_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button9.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "08" Then
            TextBox2.Text = ("Charleville-Mézières est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button10_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button10.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "09" Then
            TextBox2.Text = (" Foix est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button11_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button11.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "10" Then
            TextBox2.Text = (" Troyes est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button12_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button12.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "11" Then
            TextBox2.Text = (" Carcassonne est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button13_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button13.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "12" Then
            TextBox2.Text = (" Rodez est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button14_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button14.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "13" Then
            TextBox2.Text = (" Marseille est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button15_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button15.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "14" Then
            TextBox2.Text = (" Caen est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button16_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button16.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "15" Then
            TextBox2.Text = (" Aurillac est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button17_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button17.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "16" Then
            TextBox2.Text = (" Angoulême est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button18_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button18.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "17" Then
            TextBox2.Text = (" La Rochelle est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button19_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button19.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "18" Then
            TextBox2.Text = (" Bourges est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button20_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button20.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "19" Then
            TextBox2.Text = (" Tulle est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button21_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button21.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "20" Then
            TextBox2.Text = (" Ajaccio et Bastia sont les chefs lieux du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button22_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button22.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "21" Then
            TextBox2.Text = (" Dijon est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button23_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button23.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "22" Then
            TextBox2.Text = (" St Brieuc est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button24_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button24.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "23" Then
            TextBox2.Text = (" Gueret est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button25_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button25.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "24" Then
            TextBox2.Text = (" Périgueux est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button26_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button26.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "25" Then
            TextBox2.Text = (" Besançon est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button27_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button27.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "26" Then
            TextBox2.Text = (" Valence est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button28_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button28.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "27" Then
            TextBox2.Text = (" Evreux est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button29_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button29.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "28" Then
            TextBox2.Text = (" Chartres est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button30_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button30.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "29" Then
            TextBox2.Text = (" Quimper est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button31_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button31.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "30" Then
            TextBox2.Text = (" Nîmes est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button32_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button32.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "31" Then
            TextBox2.Text = (" Toulouse est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button33_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button33.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "32" Then
            TextBox2.Text = (" Auch est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button34_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button34.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "33" Then
            TextBox2.Text = (" Bordeaux est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button35_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button35.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "34" Then
            TextBox2.Text = (" Montpellier est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button36_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button36.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "35" Then
            TextBox2.Text = (" Rennes est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button37_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button37.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "36" Then
            TextBox2.Text = (" Chateauroux est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button38_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button38.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "37" Then
            TextBox2.Text = (" Tours est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button39_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button39.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "38" Then
            TextBox2.Text = (" Grenoble est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button40_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button40.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "39" Then
            TextBox2.Text = (" Lons-le-Saunier est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button41_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button41.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "40" Then
            TextBox2.Text = (" Mont-de-Marsan est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button42_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button42.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "41" Then
            TextBox2.Text = (" Blois est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button43_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button43.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "42" Then
            TextBox2.Text = (" St Etienne est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button44_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button44.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "43" Then
            TextBox2.Text = (" Le Puy-en-Velay est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button45_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button45.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "44" Then
            TextBox2.Text = (" Nantes est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button46_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button46.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "45" Then
            TextBox2.Text = (" Orléans est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button47_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button47.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "46" Then
            TextBox2.Text = (" Cahors est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button48_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button48.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "47" Then
            TextBox2.Text = (" Agen est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If

    End Sub

    Private Sub Button49_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button49.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "48" Then
            TextBox2.Text = (" Mende est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button50_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button50.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "49" Then
            TextBox2.Text = (" Angers est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button51_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button51.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "50" Then
            TextBox2.Text = (" St Lô est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button52_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button52.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "51" Then
            TextBox2.Text = (" Châlons-en Marne est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button53_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button53.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "52" Then
            TextBox2.Text = (" Chaumont est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button54_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button54.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "53" Then
            TextBox2.Text = (" Laval est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button55_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button55.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "54" Then
            TextBox2.Text = (" Nancy est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button56_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button56.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "55" Then
            TextBox2.Text = (" Bar-le-Duc est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button57_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button57.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "56" Then
            TextBox2.Text = (" Vannes est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button58_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button58.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "57" Then
            TextBox2.Text = (" Metz est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button59_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button59.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "58" Then
            TextBox2.Text = (" Nevers est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button60_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button60.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "59" Then
            TextBox2.Text = (" Lille est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button61_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button61.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "60" Then
            TextBox2.Text = (" Beauvais est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button62_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button62.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "61" Then
            TextBox2.Text = (" Alençon est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button63_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button63.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "62" Then
            TextBox2.Text = (" Arras est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button64_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button64.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "63" Then
            TextBox2.Text = (" Clermont Ferrand est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button65_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button65.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "64" Then
            TextBox2.Text = (" Pau est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button66_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button66.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "65" Then
            TextBox2.Text = (" Tarbes est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button67_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button67.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "66" Then
            TextBox2.Text = (" Perpignan est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button68_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button68.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "67" Then
            TextBox2.Text = (" Strasbourg est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button69_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button69.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "68" Then
            TextBox2.Text = (" Colmar est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button70_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button70.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "69" Then
            TextBox2.Text = (" Lyon est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button71_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button71.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "70" Then
            TextBox2.Text = (" Vesoul est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button72_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button72.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "71" Then
            TextBox2.Text = (" Mâcon est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button73_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button73.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "72" Then
            TextBox2.Text = (" Le Mans est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button74_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button74.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "73" Then
            TextBox2.Text = (" Chambéry est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button75_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button75.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "74" Then
            TextBox2.Text = (" Annecy est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button76_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button76.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "75" Then
            TextBox2.Text = (" Paris est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button77_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button77.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "76" Then
            TextBox2.Text = (" Rouen est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button78_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button78.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "77" Then
            TextBox2.Text = (" Melun est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button79_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button79.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "78" Then
            TextBox2.Text = (" Versailles est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button80_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button80.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "79" Then
            TextBox2.Text = (" Niort est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button81_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button81.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "80" Then
            TextBox2.Text = (" Amiens est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button82_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button82.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "81" Then
            TextBox2.Text = (" Albi est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button83_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button83.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "82" Then
            TextBox2.Text = (" Montauban est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button84_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button84.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "83" Then
            TextBox2.Text = (" Toulon est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button85_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button85.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "84" Then
            TextBox2.Text = (" Avignon est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button86_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button86.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "85" Then
            TextBox2.Text = (" La Roche sur Yon est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button87_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button87.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "86" Then
            TextBox2.Text = (" Poitiers est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button88_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button88.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "87" Then
            TextBox2.Text = (" Limoges est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button89_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button89.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "88" Then
            TextBox2.Text = (" Epinal est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button90_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button90.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "89" Then
            TextBox2.Text = (" Auxerre est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button91_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button91.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "90" Then
            TextBox2.Text = (" Belfort est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button92_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button92.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "91" Then
            TextBox2.Text = (" Evry est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button93_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button93.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "92" Then
            TextBox2.Text = (" Nanterre est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button94_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button94.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "93" Then
            TextBox2.Text = (" Bobigny est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button95_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button95.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "94" Then
            TextBox2.Text = (" Créteil est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub

    Private Sub Button96_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button96.Click
        Dim aNumber As String = ""
        If TextBox1.Text = "" Then
            TextBox2.Text = ("Entrez un numéro de département " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        ElseIf TextBox1.Text = "95" Then
            TextBox2.Text = (" Pontoise est le chef lieu du  " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\tada.wav", AudioPlayMode.Background)
        Else : TextBox1.Text = TextBox1.Text
            TextBox2.Text = ("Ce n'est pas la bonne place, essayez de nouveau le " & TextBox1.Text)
            My.Computer.Audio.Play(Application.StartupPath & "\ringin.wav", AudioPlayMode.Background)
        End If
    End Sub
    'On quitte en demandant une réponse
    Private Sub btnquit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnquit.Click
        Dim answer As MsgBoxResult
        answer = MsgBox("Voulez-vous quitter le jeu maintenant?", MsgBoxStyle.YesNo)
        If answer = MsgBoxResult.Yes Then
            MsgBox("Jeu terminé")
            End
        End If
    End Sub
End Class

 Conclusion

Pour les possesseurs de VB2005 je me tiens à leur disposition pour le Zip, car il ne passe pas sur le site il fait 2,6 Mo, donc trop lourd

 Fichier Zip

Les Membres Club peuvent télécharger directement un fichier contenu dans le zip sans télécharger le zip en entier !
  • Departement.xlsTélécharger ce fichier [Réservé aux membres club]824 320 octets

Télécharger le zip


 Historique

19 septembre 2007 11:17:24 :
Rectif Public Class Form1 Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
19 septembre 2007 18:47:45 :
Quand j'ai copié l'exemple j'ai oublé de changer Player par Departement, voilà c'est fait
10 mars 2008 16:35:38 :
J'ai mis la source complète, comme me l'a suggéré "ICONS" Ensuite j'ai mis un chemin dans le programme pour les fichiers wav,à l'attention de "RENFIELD". J'ai tardé un peu car il a fallu que j'apprenne grâce à "VB Codes Sources.
02 avril 2008 18:46:16 :
Ajout du zip en VBA Excel.Je l'ai fait avec des ComboBox pour les N° et les chefs-lieux des départements

 Sources du même auteur

Source avec Zip Source avec une capture Source .NET (Dotnet) CREER UN GIF ANIMÉ
Source avec Zip Source .NET (Dotnet) EXPORTER LES IMAGES DE WORD ET D' EXCEL
Source avec Zip Source avec une capture COLLECTION ID
Source avec Zip PROTECTION VBAPROJECT
Source avec Zip PASSWORD CLASSEUR EXCEL

 Sources de la même categorie

Source avec Zip Source avec une capture Source .NET (Dotnet) JEU DE MÉMOIRE CLASSIQUE par raffika
Source avec Zip Source avec une capture Source .NET (Dotnet) DES CHIFFRES ET DES LETTRES par ShayW
Source avec Zip Source avec une capture FAIRE REBONDIR PLUSIEURS BALLES par pierreh51
Source avec Zip Source .NET (Dotnet) JE DES BRIQUES MOUVANTES par alpha5
Source avec Zip Source avec une capture TOWER BATTLE 2 par Softmama

 Sources en rapport avec celle ci

Source avec Zip Source avec une capture FAIRE REBONDIR PLUSIEURS BALLES par pierreh51
VB6 - DÉPLACEMENT D'UN CONTRÔLE SUR UN SEGMENT DE DROITE DÉL... par ucfoutu
Source avec Zip MODIFICATION SUR UN TIC_TAC_TOE par Guyguy1011
Source avec Zip PARAMETRES SETTINGS VBA par Le Pivert
Source .NET (Dotnet) AMUSONS NOUS AVEC UN LABEL ^^ par Adn56

Commentaires et avis

Commentaire de loloof64 le 19/09/2007 11:00:42

Salut LePivert,

je suis un grand blaireau et donc j'ai bataillé et réussi à me construire le formulaire (en ayant utilisé mon cerveau)

malheureusement, il me manque la procédure de demarrage (form_load() )
pourrais-tu m'en dire plus s'il te plait.
Si ca te prend trop de temps de tout me dire, tu peux toujours aller à l'essentiel : je saurais me débrouiller.

Y a t il une image associée au jeu ? Si oui, où la télécharger .

Au plaisir :)

Commentaire de loloof64 le 19/09/2007 11:04:17

Ah oui, pas form1_load() mais form1_new(), s'il te plait .
Au plaisir :)

Commentaire de Renfield le 19/09/2007 16:47:52 administrateur CS

"C:\Windows\Media\chimes.wav"

ou le vilain (très vilain) chemin en dur...

Commentaire de Le Pivert le 19/09/2007 17:37:35

J'ai trouvé ce chemin dans un exemple de VB2005
Le Pivert

Commentaire de econs le 19/09/2007 17:41:27 administrateur CS

"vous situez le département correctement et vous avez le chef-lieu"

=> Pour l'instant, c'est pas vraiment le cas, sauf pour les habitants de l'Ain. La source devrait être finie.
Un tableau du même style que players() (dont le nom m'échappe un peu d'ailleurs) fera très bien l'affaire. Tu n'auras alors pas besoin de faire 94 If supplémentaires.


Et si j'écris 100, ou bien AAAA dans TextBox1, que se passera-t-il ?


# TextBox1.Text = TextBox1.Text
Dans quel but ?

TextBox2 peut aisément être remplacé par un Label. Une TextBox est faite pour permettre la saisie de l'utilisateur, alors qu'un label ne fait que de l'affichage de texte, ce qui est le cas ici.

Commentaire de econs le 19/09/2007 17:45:03 administrateur CS

LePivert> En fait, aucun chemin ne devrait se trouver en dur dans un code. Je n'ai pas de répertoire "C:\Windows" sur mon PC, mais un "C:\WINNT", ce qui fait qu'en l'état, ton code ne peut pas fonctionner chez moi.

Si tu livrais une source complète avec tous ses fichiers (*.vb, *.sln, ...), çà deviendrait plus portable.

Commentaire de loloof64 le 19/09/2007 18:24:51

Loloof64 dit le silence est d'or

Commentaire de Le Pivert le 19/09/2007 18:30:45

Je n'ai pas copié la totalité du code, mais, la suite et la même que l'Ain (c'est vrai le code est très long mais je suis débutant). Pour ce qui est du TextBox1=TextBox1, c'est pour éviter en cas d'erreur de département à avoir à retaper la saisie.En cas d'erreur de saisie:AAA, un message s'affiche dans le TextBox2(cela aurait était peut être mieux avec un label.

Commentaire de starket le 10/03/2008 11:56:16

Tu pourrais faire tourner ton zip stp ??
Merci

Commentaire de Le Pivert le 10/03/2008 16:41:38

Pour répondre à "Econs" et à "RENFIELD" que je remercie pour leur critique constructive, j'ai mis une mise à jour avec le chemin wav rectifié. Mais comme je l'explique dans la mise à jour il a fallu que j'apprenne, votre site est super même pour un débutant( c'est un peu plus long)

 Ajouter un commentaire


Discussions en rapport avec ce code source dans le forum

ComboBox et Tableau Array [ par Jeffbris07 ] SalutJ'aimerais savoir comment pourrais-je r&#233;cup&#233;rer de l'information d'un tableau Array&nbsp;&#224; partir d'un combobox.&nbsp; En fait, j' Une variable pour former une liste [ par CryoCid ] Bonjours à tous,Je viens vous solliciter aujourd'hui car je me demandais si il était possible de créer une variable pour regrouper un certain nombre d le problém de combobox [ par kimonador ] salut,  jai un combo ki contien plusieur code_chapitre jai un autre combo ki contient plusieur code_articlesi je seléctioné code-chapitre  ex: 10 le c VBA ComboBox [ par damiros ] Bonjour à tous, VB - Visual Studio 2008 - Combobox multi-colonnes [ par newvicking ] Bonjour,   <p class="MsoNormal" st Combobox [ par Boulgor ] Bonjour,tout d'abord excusez moi si je me suis trompé de rubrique mais y en un sacré paquet^^.J'explique mon problème:je suis entrain de créer un fich Initialisation des combobox [ par Boulgor ] Salut à tous,J'ai crée sur un document plusieurs combobox qui figure sur la première feuille de celui-ci.Chaques combobox (3 au total), présente une l combobox [ par temsehs ] Bonjour;j'utilise le VB.net pour developper une petite application de gestionmais pour ComboBox j'ai trouver un petit problemme qui est; je veut rempl vb.net + combobox [ par temsehs ] Bonjour;j'utilise le VB.net pour developper une petite application de gestionje veut remplir la liste de combo bax avec un champ ou bien 2 champs d'un Combobox [ par tallia64 ] Bonjour je travaille dans un userform "Entrée" où j'ai deux combobox déroulantes l'une qui gère des catégories "visiteur,hotellerie" l'autre des numér


Nos sponsors


Sondage...

CalendriCode

Février 2012
LMMJVSD
  12345
6789101112
13141516171819
20212223242526
272829    

Consulter la suite du CalendriCode

 
Développement réalisé par Nicolas SOREL (Nix) avec l'aide de : Cyril DURAND et Emmanuel (EBArtSoft), Merci à Vincent pour ses précieux conseils.
CodeS-SourceS.com© Toute reproduction même partielle est interdite sauf accord écrit du Webmaster
CodeS-SourceS.com© est une marque déposée tous droits réservés

Google Coop CodeS-SourceS Google Coop CodeS-SourceS
Temps d'éxécution de la page : 1,981 sec (3)

Nous contacter | Annoncer sur CodeS-SourceS | Mentions légales