Thanks,
I can't put start time and end time in different columns.
I have all of them on the same column, and another column that is set to 1 if it is entrance or 0 if it is exit.
Anyt other idea?
Thanks,
Quote:
Originally Posted by GS[_2_]
Enter the dates of StartTime in column 'A';
Enter the StartTime in column 'B';
Enter the StopTime in column 'C';
Enter the following formula in column 'D'...
=IF(AND($B2<"",$C2<""),ROUND(MOD($C2-$B2,1)*24,2),"")
...where row 1 has headings and your time records start in row 2.
The formula returns time in hundredths of an hour, and accounts for
starts before midnight that include stops after midnight. If either
StartTime or StopTime is empty the result is blank until both fields
have valid times entered. So...
Start=1:00 PM; Stop=5:30 PM; ElapsedTime=4.5 hours
Start=9:00 PM; Stop=1:30 AM; ElapsedTime=4.5 hours
Copy the formula down.
It's okay to have multiple start/stop sessions for the same date.
Use the AutoSum feature to total how you want.
You can enter start/stop times 'on-the-fly' using the keyboard combo
'Ctrl+Shift+;' if you work multiple projects in any workday.
HTH
--
Garry
Free usenet access at http://www.eternal-september.org
ClassicVB Users Regroup!
comp.lang.basic.visual.misc
microsoft.public. vb.general.discussion
|