cmonhackns.n-stars.org
Would you like to react to this message? Create an account in a few clicks or log in to continue.


Indonesian SWF Editor Community
 
HomeLatest imagesRegisterLog in
SELAMAT Datang Di Cmonhackns ===> Mulailah dari yang kecil... karena semua yang besar dulunya juga kecil..

 

 Membuat Stopwatch Di Visual Basic 2008

Go down 
4 posters
AuthorMessage
aaa123
Warga Lama
Warga Lama
aaa123


Jumlah posting : 63
Join date : 2011-04-23
Age : 25
Lokasi : Di Hatimu

Membuat Stopwatch Di Visual Basic 2008 Empty
PostSubject: Membuat Stopwatch Di Visual Basic 2008   Membuat Stopwatch Di Visual Basic 2008 Icon_minitime1Thu Aug 04, 2011 5:06 pm

[You must be registered and logged in to see this image.]
untuk membuat stopwatch yang harus di lakukan :

1. add button di toolbox beri nama button1
2. add label di toolbox beri nama label1
3. add timer di toolbox beri nama timer1

Tambahkan variable terlebih dahulu
Code:
 Dim detik, menit, jam As Integer
    Dim a As Boolean
didalam koding dibawah Public Class Form1

sertakan koding ini juga
Code:
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        Timer1.Enabled = False
        a = True
    End Sub
setelah itu

doubleklik button1 nya dan masukan koding berikut
Code:
 If a = True Then
            Timer1.Start()
            a = False
        Else
            Timer1.Stop()
            a = True
        End If
doubleklik timer1 dan masukan koding berikut
Code:
If detik = 60 Then
            detik = 0
            menit = menit + 1
        End If
        If menit = 60 Then
            If detik = 0 Then
                detik = 0
                menit = 0
                jam = jam + 1
            End If
        End If
        detik = detik + 1
        Label1.Text = Format(jam, "00") & ":" & Format(menit, "00") & ":" & Format(detik, "00")
selesai



koding akhirnya harus seperti ini
Code:
Public Class Form1
    Dim detik, menit, jam As Integer
    Dim a As Boolean
    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click

        If a = True Then
            Timer1.Start()
            a = False
        Else
            Timer1.Stop()
            a = True
        End If

    End Sub

    Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
        If detik = 60 Then
            detik = 0
            menit = menit + 1
        End If
        If menit = 60 Then
            If detik = 0 Then
                detik = 0
                menit = 0
                jam = jam + 1
            End If
        End If
        detik = detik + 1
        Label1.Text = Format(jam, "00") & ":" & Format(menit, "00") & ":" & Format(detik, "00")
    End Sub

    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        Timer1.Enabled = False
        a = True
    End Sub
End Class
Back to top Go down
http://aaa123.cixx6.com
Vierra
Admin
Admin
Vierra


Jumlah posting : 876
Join date : 2011-06-10
Age : 26

Membuat Stopwatch Di Visual Basic 2008 Empty
PostSubject: Re: Membuat Stopwatch Di Visual Basic 2008   Membuat Stopwatch Di Visual Basic 2008 Icon_minitime1Thu Aug 04, 2011 5:46 pm

aaa123 wrote:
[You must be registered and logged in to see this image.]
untuk membuat stopwatch yang harus di lakukan :

1. add button di toolbox beri nama button1
2. add label di toolbox beri nama label1
3. add timer di toolbox beri nama timer1

Tambahkan variable terlebih dahulu
Code:
 Dim detik, menit, jam As Integer
    Dim a As Boolean
didalam koding dibawah Public Class Form1

sertakan koding ini juga
Code:
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        Timer1.Enabled = False
        a = True
    End Sub
setelah itu

doubleklik button1 nya dan masukan koding berikut
Code:
 If a = True Then
            Timer1.Start()
            a = False
        Else
            Timer1.Stop()
            a = True
        End If
doubleklik timer1 dan masukan koding berikut
Code:
If detik = 60 Then
            detik = 0
            menit = menit + 1
        End If
        If menit = 60 Then
            If detik = 0 Then
                detik = 0
                menit = 0
                jam = jam + 1
            End If
        End If
        detik = detik + 1
        Label1.Text = Format(jam, "00") & ":" & Format(menit, "00") & ":" & Format(detik, "00")
selesai



koding akhirnya harus seperti ini
Code:
Public Class Form1
    Dim detik, menit, jam As Integer
    Dim a As Boolean
    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click

        If a = True Then
            Timer1.Start()
            a = False
        Else
            Timer1.Stop()
            a = True
        End If

    End Sub

    Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
        If detik = 60 Then
            detik = 0
            menit = menit + 1
        End If
        If menit = 60 Then
            If detik = 0 Then
                detik = 0
                menit = 0
                jam = jam + 1
            End If
        End If
        detik = detik + 1
        Label1.Text = Format(jam, "00") & ":" & Format(menit, "00") & ":" & Format(detik, "00")
    End Sub

    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        Timer1.Enabled = False
        a = True
    End Sub
End Class
wew, Nice Share gan, ini bisa di pake di VB 6 g ?
ane g pnya VB 8 Membuat Stopwatch Di Visual Basic 2008 116129
Back to top Go down
K a c a n g
Warga Lama
Warga Lama
K a c a n g


Jumlah posting : 228
Join date : 2011-02-06
Age : 34

Membuat Stopwatch Di Visual Basic 2008 Empty
PostSubject: Re: Membuat Stopwatch Di Visual Basic 2008   Membuat Stopwatch Di Visual Basic 2008 Icon_minitime1Thu Aug 04, 2011 7:43 pm

tutornya kurang jelas bro..dan ini creditnya siapa bro Membuat Stopwatch Di Visual Basic 2008 11087 ?
Back to top Go down
http://www.google.com
Alex_Njsg
Sesepuh
Sesepuh
Alex_Njsg


Jumlah posting : 390
Join date : 2011-01-10
Age : 33
Lokasi : Hidden

Membuat Stopwatch Di Visual Basic 2008 Empty
PostSubject: Re: Membuat Stopwatch Di Visual Basic 2008   Membuat Stopwatch Di Visual Basic 2008 Icon_minitime1Thu Aug 04, 2011 8:02 pm

K a c a n g wrote:
tutornya kurang jelas bro..dan ini creditnya siapa bro Membuat Stopwatch Di Visual Basic 2008 11087 ?

saya rasa sangat jelas tutornya itu Membuat Stopwatch Di Visual Basic 2008 11087
Back to top Go down
K a c a n g
Warga Lama
Warga Lama
K a c a n g


Jumlah posting : 228
Join date : 2011-02-06
Age : 34

Membuat Stopwatch Di Visual Basic 2008 Empty
PostSubject: Re: Membuat Stopwatch Di Visual Basic 2008   Membuat Stopwatch Di Visual Basic 2008 Icon_minitime1Thu Aug 04, 2011 8:14 pm

ga jelas yg ini bro tutornya
Spoiler:
ama yg ini
Spoiler:
Back to top Go down
http://www.google.com
aaa123
Warga Lama
Warga Lama
aaa123


Jumlah posting : 63
Join date : 2011-04-23
Age : 25
Lokasi : Di Hatimu

Membuat Stopwatch Di Visual Basic 2008 Empty
PostSubject: Re: Membuat Stopwatch Di Visual Basic 2008   Membuat Stopwatch Di Visual Basic 2008 Icon_minitime1Fri Aug 05, 2011 2:39 pm

K a c a n g wrote:
tutornya kurang jelas bro..dan ini creditnya siapa bro Membuat Stopwatch Di Visual Basic 2008 11087 ?
credit saya sendiri
K a c a n g wrote:
ga jelas yg ini bro tutornya
Spoiler:
ama yg ini
Spoiler:
maksudnya gk jelas giman bro
Back to top Go down
http://aaa123.cixx6.com
Sponsored content





Membuat Stopwatch Di Visual Basic 2008 Empty
PostSubject: Re: Membuat Stopwatch Di Visual Basic 2008   Membuat Stopwatch Di Visual Basic 2008 Icon_minitime1

Back to top Go down
 
Membuat Stopwatch Di Visual Basic 2008
Back to top 
Page 1 of 1
 Similar topics
-
» Membuat Progress bar pada visual basic 6
» Cara membuat Virus Pake Visual BAsic 6.0
» Membuat Anti Virus Visual Basic 2010 Express
» Link Visual Basic 6.0 Portable + contoh membuat form login
» Tutorial buat keylogger sendiri dengan Visual Basic 2010

Permissions in this forum:You cannot reply to topics in this forum
cmonhackns.n-stars.org :: Computer Freakz :: All About Programming :: Visual Basic-
Jump to: