Skip to content

How to add clock timer to listview column ?

Viewing 7 posts - 16 through 22 (of 22 total)
  • Author
    Posts
  • #187913

    LOL 😯 😯 😯 😯 😯

    #187912

    see it now baby

    #187911
    autopilot
    Member

    @method wrote:

    autopilot i wish i had visual basic 2005 edtion. So i don’t know how to modify it for vb6!!!

    Get VB2005 Express free from Microsoft. Download it here!

    autopilot

    #187910

    one day vb6 programmers have to move to vbnet becuz microsoft won’t support vb6. BTW autopilot why you do a lot of thing for nothing, the formula shown is so simple and can be used in vbnet or c#

    example hour.ToString(“00”) ect

    #187909
    autopilot
    Member

    @BattleStar-Galactica wrote:

    BTW autopilot why you do a lot of thing for nothing, the formula shown is so simple and can be used in vbnet or c#

    example hour.ToString(“00”) ect

    Well… the reason is simple… didn’t know i could do it that way 🙂 Thanks for the tip

    autopilot

    What my timer became:

        Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
    'increase sec by 1
    sec += 1
    'process sec
    If sec > 59 Then
    sec = 0
    min += 1
    s = "00"
    Else
    s = sec.ToString("00")
    End If
    'process min
    If min > 59 Then
    min = 0
    hour += 1
    m = "00"
    Else
    m = min.ToString("00")
    End If
    'process hour
    h = hour.ToString("00")
    'update the listview
    ListView1.Items.Item(0).Text = String.Format("{0}:{1}:{2}", h, m, s)
    End Sub
    #187908
    method
    Member

    Batler thank you for the project. But timer doesn’t go beyond one min!! In other word it doesn’t show mins and hours!!

    #187907

    Sorry for that, I didn’t run the program, just do copy and past what I posted on here, now I run it and see an error of logic

    just redownload the project here, it’s will ok

Viewing 7 posts - 16 through 22 (of 22 total)
  • You must be logged in to reply to this topic.