Hai, lama nih nggak ngepost. Sekali kali ngepost lah ... Ya.. Ya.. Ya... (Demam Cocokologi). Kali ini saya akan membuat tutorial membuat program acak angka dengan VB 6.0 . Cukuplah basa basinya, langsung aja.
Langkah - Langkah :
1. Buatlah Form seperti ini :
2. Atur Properties seperti ini :
label1
-name = angka
-aligment = 2-center
-backstyle = 0- transparent
-borderstyle =1-fixed single
-caption="0"
-font= courier 72 regular 72
timer1
-enable=false
-intecval=100
command1
-caption="angka"
3. klik kanan form -> View Code
4. Paste Code dibawah ini :
Dim x As Boolean
Private Sub Command1_Click()
If x = False Then
Timer1.Enabled = True
Command1.Caption = "STOP"
x = True
Else
Timer1.Enabled = False
Command1.Caption = "ACAK"
x = False
End If
End Sub
Private Sub Form_Load()
Timer1.Enabled = False
x = False
angka = 0
Command1.Caption = "ACAK"
End Sub
Private Sub Timer1_Timer()
angka.Caption = Int(Rnd * 10)
End Sub
5. Tekan F5 untuk Running.. Tada...!! program sudah jadi.
Atau anda dapat mengunduh source code lengkapnya DISINI
Langkah - Langkah :
1. Buatlah Form seperti ini :
2. Atur Properties seperti ini :
label1
-name = angka
-aligment = 2-center
-backstyle = 0- transparent
-borderstyle =1-fixed single
-caption="0"
-font= courier 72 regular 72
timer1
-enable=false
-intecval=100
command1
-caption="angka"
3. klik kanan form -> View Code
4. Paste Code dibawah ini :
Dim x As Boolean
Private Sub Command1_Click()
If x = False Then
Timer1.Enabled = True
Command1.Caption = "STOP"
x = True
Else
Timer1.Enabled = False
Command1.Caption = "ACAK"
x = False
End If
End Sub
Private Sub Form_Load()
Timer1.Enabled = False
x = False
angka = 0
Command1.Caption = "ACAK"
End Sub
Private Sub Timer1_Timer()
angka.Caption = Int(Rnd * 10)
End Sub
5. Tekan F5 untuk Running.. Tada...!! program sudah jadi.
Atau anda dapat mengunduh source code lengkapnya DISINI
Sign up here with your email

2 komentar
Write komentarwah bisa dicoba nih bagus buat togel
Replyharam gan.. btw thx kunjungannya!!!
ReplyConversionConversion EmoticonEmoticon