Time help

socko139

Registered User.
Local time
Today, 06:09
Joined
Feb 22, 2001
Messages
25
All,

I need some help with one of my forms. I want to create a Form in excel with a macro button. When this button is clicked it will take the system time off the computer and post it to a text box or label in the form. Any ideas? I know part of it is MyTime = Time, but how do I now post this to a text box sitting right next to the button on my form. Any help would be great ... Thanks!!!
 
Assuming your text box is called "Text1" then a line of code like:-

Me![text1] = mytime

HTH
 
When I entered these lines of code for my command button..then clicked it... no times were placed in my textbox(TextBox1) Anything Im leaving out?

Private Sub CommandButton1_Click()
Me![TextBox1] = mytime
End Sub
 
Access has a Time() function. Excel probably does also.

Me![TextBox1] = Time()
 

Users who are viewing this thread

Back
Top Bottom