Public Class Form1 Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Timer1.Start() End Sub Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick ProgressBar1.Increment(2) If ProgressBar1.Value = 100 Then Timer1.Stop() MsgBox("Appuyer sur OK pour afficher votre code") ProgressBar1.Value = 0 TextBox2.Text = Int(Rnd() * 20) Select Case TextBox2.Text Case 0 TextBox2.Text = "45F3-98FR-87FV" Case 1 TextBox2.Text = "85FR-F8E5-E8C6" Case 2 TextBox2.Text = "D2A3-33RE-98DP" Case 3 TextBox2.Text = "17AM-88CT-96E5" Case 4 TextBox2.Text = "85DF-5V9R-FTG4" Case 5 TextBox2.Text = "D62C-7DCC-DR7V" Case 6 TextBox2.Text = "985F-F1CS-7DF1" Case 7 TextBox2.Text = "56AX-M6NU-A81C" Case 8 TextBox2.Text = "N1K3-T4GM-PD75" Case 9 TextBox2.Text = "B2OB-AIZI-GR0S" Case 10 TextBox2.Text = "ER85-14A3-84CE" Case 11 TextBox2.Text = "9DH6-27TM-XP36" Case 12 TextBox2.Text = "5D53-75F1-89AQ" Case 13 TextBox2.Text = "AM12-R53C-4IR1" Case 14 TextBox2.Text = "M4XE-B1LL-UNI7" Case 15 TextBox2.Text = "BL85-C98I-L15E" Case 16 TextBox2.Text = "ENF1-NB0N-MDR4" Case 17 TextBox2.Text = "69D3-58A9-892D" Case 18 TextBox2.Text = "85S6-RG47-8ED2" Case 19 TextBox2.Text = "XD45-LY69-M13D" Case 20 TextBox2.Text = "L96F-BO2A-8D52" End Select End If End Sub Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load End Sub End Class
Vous n’avez pas trouvé la réponse que vous recherchez ?
Posez votre questionPublic class form1 'blabla End class