form1 kodları
Programın hazır exe halini Burdan indirebilirsiniz
--------------------------------
Dim kur As Byte
Dim dakika As Byte
Dim saat As Byte
Private Sub Command1_Click()
kur = Val(Combo1.List(Combo1.ListIndex))
dakika = Mid(Label1.Caption, 4, 2)
saat = Mid(Label1.Caption, 1, 2)
If Combo1.Text = "" Then
MsgBox "Lütfen Dakikayı giriniz...", vbOKOnly + 16, "Uyarı..."
Else
Label6.Caption = ":"
If kur + dakika >= 60 Then
Label2.Caption = kur + dakika - 60
Else
Label2.Caption >= kur + dakika
End If
If kur + dakika > 60 Then
Label3.Caption = saat + 1
Else
Label3.Caption = saat
End If
If Len(Label2.Caption) = 1 Then Label2.Caption = "0" & Label2.Caption
If Len(Label3.Caption) = 1 Then Label3.Caption = "0" & Label3.Caption
End If
End Sub
Private Sub Command2_Click()
Label3.Caption = ""
Label2.Caption = ""
Label6.Caption = ""
End Sub
Private Sub Timer1_Timer()
sistem = Time
Label1.Caption = Mid(sistem, 1, 5)
If Mid(Time, 1, 2) = Label3.Caption And Mid(Time, 4, 2) = Label2.Caption Then
Form2.Show
End If
End Sub
------------------
Form2 kodları
---------------
Private Sub Command1_Click()
End
End Sub
Private Sub Form_Load()
Timer1.Enabled = True
Timer1.Interval = 1000
Label2.Caption = "20"
End Sub
Private Sub Timer1_Timer()
Label2.Caption = Val(Label2.Caption) - 1
If Label2.Caption = "0" Then
Shell ("c:/windows/system32/shutdown.exe -s -t 0")
End
End If
Programın hazır exe halini Burdan indirebilirsiniz
--------------------------------
Dim kur As Byte
Dim dakika As Byte
Dim saat As Byte
Private Sub Command1_Click()
kur = Val(Combo1.List(Combo1.ListIndex))
dakika = Mid(Label1.Caption, 4, 2)
saat = Mid(Label1.Caption, 1, 2)
If Combo1.Text = "" Then
MsgBox "Lütfen Dakikayı giriniz...", vbOKOnly + 16, "Uyarı..."
Else
Label6.Caption = ":"
If kur + dakika >= 60 Then
Label2.Caption = kur + dakika - 60
Else
Label2.Caption >= kur + dakika
End If
If kur + dakika > 60 Then
Label3.Caption = saat + 1
Else
Label3.Caption = saat
End If
If Len(Label2.Caption) = 1 Then Label2.Caption = "0" & Label2.Caption
If Len(Label3.Caption) = 1 Then Label3.Caption = "0" & Label3.Caption
End If
End Sub
Private Sub Command2_Click()
Label3.Caption = ""
Label2.Caption = ""
Label6.Caption = ""
End Sub
Private Sub Timer1_Timer()
sistem = Time
Label1.Caption = Mid(sistem, 1, 5)
If Mid(Time, 1, 2) = Label3.Caption And Mid(Time, 4, 2) = Label2.Caption Then
Form2.Show
End If
End Sub
------------------
Form2 kodları
---------------
Private Sub Command1_Click()
End
End Sub
Private Sub Form_Load()
Timer1.Enabled = True
Timer1.Interval = 1000
Label2.Caption = "20"
End Sub
Private Sub Timer1_Timer()
Label2.Caption = Val(Label2.Caption) - 1
If Label2.Caption = "0" Then
Shell ("c:/windows/system32/shutdown.exe -s -t 0")
End
End If
Son düzenleme:



