View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.misc
Hanr3
 
Posts: n/a
Default Time calculation for attendance, tardy/late to work?

Thanks for your help so far.
This is what I have as of now.
I had to create another column and formatted as hh:mm Then insert the
formula MOD(B2,1). This gave me the time value of the starttime (column B2)
which was Date/Time and pulled from the timeclock application.
Then for the If statement it looks like so.
IF((F2=G2),"OK",IF((F2<G2),"Early",IF((F2G2),"Tar dy",)))
F=Mod(starttime,1)
G=Employee daily start time.

Now the only issue sleft to resolve is the seconds. I need to round them
down in column F. MOD(B2,1) is the current formula in column F.
Any ideas?
Or would it be better to add 1 minute to the employee start time?

--
Life is an adventure, are you living it?

These are just my opinions, please feel free to correct them if they are
wrong.


"Simon G" wrote:

Try this equation:

=IF(B7-A70, "late", "ok")

eg:

Due time Start time result
7:00:00 6:58:00 ok
7:00:00 7:00:00 ok
7:00:00 7:00:01 late

Have your employee name (or ID) and dates as separate columns (better for
sorting etc.)

Format your A & B Columns as time (hh:mm:ss), you can subtract either one
from the other, but you have to ensure that you don't result in a negative
time, as Excel won't like it. (Lets be honest you can't actually have
negative time)

"mrice" wrote:


You could test the value of your subtraction for being greater than or
less than zero and get your tru or false that way.


--
mrice

Research Scientist with many years of spreadsheet development experience
------------------------------------------------------------------------
mrice's Profile: http://www.excelforum.com/member.php...o&userid=10931
View this thread: http://www.excelforum.com/showthread...hreadid=540312