Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Making a clock in access

Posted on 2012-03-21
3
250 Views
Last Modified: 2012-03-21
I have a clock that I'm working with. I found the code on this website:

http://office.microsoft.com/en-us/access-help/add-clock-control-functionality-to-a-form-in-access-HP001121061.aspx?CTT=5&origin=HA001054662

It tells you step by step what to do. However, there is one part of the code that I wasn't sure about and it is the following step:

Paste the following line of code into the subroutine in the Visual Basic Editor code window to call the user-defined function ClockLoadDate, which will update the clock controls. Replace ActualArrivalTime with the name of the control that is bound to the underlying date/time field.
ClockLoadDate Nz(ActualArrivalTime, "")


For "ActualArivalTime" Im not sure what underlying date/time field should be which text box do I replace "ActualArivalTime" with.
Below is the form.
Copy-of-Inventory-db.accdb
0
Comment
Question by:gigifarrow
  • 2
3 Comments
 
LVL 77

Expert Comment

by:peter57r
ID: 37747933
ActualArrivalTime is the name of the textbox to the left of the h/m/s controls in the example.
0
 

Author Comment

by:gigifarrow
ID: 37748641
My clock is still not working. I keep getting a error,"Can't find End Sub". I look at the bottom and there is  a End Sub.
0
 
LVL 77

Accepted Solution

by:
peter57r earned 500 total points
ID: 37748705
No - you are looking at the bottom of the module.

Each sub procedure must have its own end sub.
The Form_Current sub does not have an End Sub.  

Private Sub Form_Current()
ClockLoadDate Nz(txHour, "")
'// This routine will change the time part + or - 1.
End Sub '  ADD THIS LINE HERE
Public Sub ClockChangeTime(oCtl As TextBox, fIncrement As Boolean)
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Using Word 2013, I was experiencing some incredible lag when typing.  Here's what worked for me....
This article descibes how to create a connection between Excel and SAP and how to move data from Excel to SAP or the other way around.
Learn how to create and modify your own paragraph styles in Microsoft Word. This can be helpful when wanting to make consistently referenced styles throughout a document or template.
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

838 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question