473,386 Members | 1,598 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Help with a time clock function

Been searching the web and various forums and can not find the answer that I need. Developing an application using MS Access 2000 and I need to include a time clock function. I have tried several different ways to store and track the data, but extracting the information for later in an easy way is the difficulty.

For example, I have 4 employees. They can clock in or clock out and it records the date/time of that action. So, in review, I know who (employee #), what (clocked in) and when (date/time stamp).

What I want to be able to do is get that information back out of table in an easy, clean way. How many hours did all the employees work on Monday? How many hours does #4 have for the week so far? You get the picture.

I see all the puzzle pieces, I just don't have a box top to start to arrange them in a smart, organized way. Suggestions? Models? Examples?

Thanks in advance.

Gene
Aug 2 '08 #1
2 1979
Dököll
2,364 Expert 2GB
Hello genen17821!

I believe you can use the DateDiff function in Access to compile a clean calculation of the hours worked for each, then calculate totals thereafter:

(1) You may need to have a check for when users are clocking out

(2) Checkboxes can be used to fire time clocked in and out

(3) Using DateDiff against TimeClockedIn, TimeClockedOut, as one example will give you number of hours, minutes, seconds, etc...

This can be pulled into your form. You can pin each Checkbox on your form, namely TimeClockedIn and TimeClockedOut to a Before or AfterUpdate type of event procedure to record a date either is checked.

Please stay here for a better idea on this. And if you have not previously searched here, I'd suggest you do, examples are surely available to fit your purpose.

Good luck with the project!

Dököll
Aug 2 '08 #2
Hello genen17821!

I believe you can use the DateDiff function in Access to compile a clean calculation of the hours worked for each, then calculate totals thereafter:

(1) You may need to have a check for when users are clocking out

(2) Checkboxes can be used to fire time clocked in and out

(3) Using DateDiff against TimeClockedIn, TimeClockedOut, as one example will give you number of hours, minutes, seconds, etc...

This can be pulled into your form. You can pin each Checkbox on your form, namely TimeClockedIn and TimeClockedOut to a Before or AfterUpdate type of event procedure to record a date either is checked.

Please stay here for a better idea on this. And if you have not previously searched here, I'd suggest you do, examples are surely available to fit your purpose.

Good luck with the project!

Dököll

Thanks for the information - will work with the datediff function as that will help. However, the main problem that I am experiencing is the best way to structure the data. I would like to leave all the data in a table and then access it, calculate on it, etc, through queries (as opposed to code) to make things easiest. The question is, how to structure that table.

For example, is it best to just have have a tblClockTime that gets recorded each time the employee clocks in our out with a tblClockActionID that denotes if its clock in or clock out? Or would it be better to have a tblClockTimeIN field and a tblClockTimeOUT field and then work with the differences there?

I think that I will work with the second option for a while pending any further updates from yourself and or other members. Thanks!

Gene
Aug 2 '08 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

9
by: Fabian | last post by:
I had a very quiet schedule at work today, so I thought I'd finish this script. In theory, it should generate a random time between two moments specified, round it off to a conventional interval if...
10
by: Sonoman | last post by:
Hi all: I am trying to write a simple program that simulates asking several persons their birth day and it counts how many persons are asked until two have the same birth day. The problem that I...
10
by: KevinL | last post by:
I'm writing a random number generator program and using time() to seed it. I found out that time() output is in seconds. Do you know of another function that outputs in thousands of seconds ? ...
6
by: Charles M. Reinke | last post by:
I'm using the function clock() to measure the run time of a program so that I can compare among several different algorithms. My code looks like: #include <stdio.h> #include <stdlib.h>...
5
by: raybakk | last post by:
Hi there. If I make a function in c (I acually use gnu right now), is there any way to find out how many clocksycluses that function takes? If I divide some numbers etc Var1 = Var2/Var3, is it...
6
by: D | last post by:
Hello all...I have an issue with one of my java script functions that I'm hoping someone can easily help with. I have a web based application that we use to create/sign up for overtime. When we...
12
by: pekka | last post by:
I'm trying to measure user input time with my Timer class object. It isn't as easy as I expected. When using std::cin between timer start and stop, I get zero elapsed time. For some unknown reason,...
9
by: Ron Adam | last post by:
I'm having some cross platform issues with timing loops. It seems time.time is better for some computers/platforms and time.clock others, but it's not always clear which, so I came up with the...
8
by: Theo v. Werkhoven | last post by:
hi, In this code I read out an instrument during a user determined period, and save the relative time of the sample (since the start of the test) and the readback value in a csv file. #v+...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.