timer poker 1.2 - tuto-informatique.seb30.overblog.com
Overblog Suivre ce blog
Editer l'article Administration Créer mon blog
tuto-informatique.seb30.overblog.com

tuto et astuce informatique,n'hesitez pas a faire un don pour le travail

timer poker 1.2

Publié le 16 Janvier 2014 par SEB in vb 2010

remise a jour du timer poker

remise a jour du timer poker

a telecharger pour les feneants

timer pour poker averti tous les 20 mins pour changement de blinde

il faut une textbox 2 timer et 1 label et 2 boutons

important le timer 1 doit etre regler 1000 et le second a 1200000

voici le programme

Public Class Form1
Dim S As Int32 = 0
Dim M As Integer = 0
Dim H As Integer = 0
Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
S = S + 1
If S >= 59 Then S = 0 : M = M + 1 : Me.Visible = True
If M > 59 Then M = 0 : H = H + 1
Label1.Text = Microsoft.VisualBasic.Strings.Right("0" & H, 2) & ":" & Microsoft.VisualBasic.Strings.Right("0" & M, 2) _
& ":" & Microsoft.VisualBasic.Strings.Right("0" & S, 2)
Timer2.Start()
End Sub


Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Timer1.Start()
Button1.Visible = False
If CheckBox1.Checked = True Then
Timer2.Interval = 900000
Timer2.Enabled = True

End If

If CheckBox2.Checked = True Then
Timer2.Interval = 1200000
Timer2.Enabled = True

End If
If CheckBox3.Checked = True Then
Timer2.Interval = 1500000
Timer2.Enabled = True

End If
If CheckBox4.Checked = True Then
Timer2.Interval = 1800000
Timer2.Enabled = True

End If
If CheckBox5.Checked = True Then
Timer2.Interval = 2700000
Timer2.Enabled = True

End If

If CheckBox6.Checked = True Then
Timer2.Interval = 300000
Timer2.Enabled = True

End If
If CheckBox7.Checked = True Then
Timer2.Interval = 600000
Timer2.Enabled = True

End If
If CheckBox8.Checked = True Then
Timer2.Interval = 120000
Timer2.Enabled = True

End If
End Sub


Private Sub Timer2_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer2.Tick
Dim SAPI
SAPI = CreateObject("sapi.spvoice")
SAPI.Speak(TextBox1.Text)
MsgBox("la blinde augmente", 64, "chrono blinde")
S = 0
M = 0
H = 0
End Sub

Private Sub LinkLabel1_LinkClicked(ByVal sender As System.Object, ByVal e As System.Windows.Forms.LinkLabelLinkClickedEventArgs) Handles LinkLabel1.LinkClicked
System.Diagnostics.Process.Start("http://tuto-informatique.seb30.overblog.com/")
End Sub


Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
Timer1.Stop()
Timer2.Stop()
Button1.Visible = True
Label1.Text = "timer poker"
S = 0
M = 0
H = 0
End Sub
End Class

Commenter cet article