Consulting

Results 1 to 3 of 3

Thread: Real Time Clock in a Textbox on a Userform

  1. #1
    VBAX Contributor
    Joined
    Aug 2011
    Posts
    126
    Location

    Real Time Clock in a Textbox on a Userform

    Anyone know how to display and capture "Real Time" on a Userform ?

    I am currently using :

    [vba]
    Private Sub UserForm_MouseMove(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
    TextBoxTime.Value = Time
    End Sub
    [/vba]

    to keep a textbox displaying the current time to record when an action is requested. This is pretty cool... and it works, but.. when the mouse rests... the textbox stops updating.

    Will it fullfill my purpose? Absolutely. I just thought it would be neat if someone knew how to keep the time update continuous while the userform was open. Eventually a user will notice the time Starting and Stopping and my phone will be ringing.

    Thanks

  2. #2
    Moderator VBAX Guru Simon Lloyd's Avatar
    Joined
    Sep 2005
    Location
    UK
    Posts
    3,003
    Location
    It's not really practicle but everything you need can be found here http://www.tushar-mehta.com/excel/software/vba_timer/
    Regards,
    Simon
    Please read this before cross posting!
    In the unlikely event you didn't get your answer here try Microsoft Office Discussion @ The Code Cage
    If I have seen further it is by standing on the shoulders of giants.
    Isaac Newton, Letter to Robert Hooke, February 5, 1675 English mathematician & physicist (1642 - 1727)

  3. #3
    VBAX Contributor
    Joined
    Aug 2011
    Posts
    126
    Location
    Thank You Simon !
    I'll check it out !

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •