View Single Post
  #4   Report Post  
Ron Rosenfeld
 
Posts: n/a
Default

On Mon, 20 Dec 2004 18:59:02 -0800, Ms Chewie <Ms
wrote:

I am trying to set-up a program to use to do my timesheets for work
electronically... I have the excel copy of the sheet directly from the
company.
I need to be able to convert the differences between a time so that it shows
up with the hour worked and to the nearest 1/4 hour. For example I need
7:31am to 11:10am to show up as 3.75, because it is 3 hours and 39 minutes
and the 39 goes to 45 after. I figured out how to get it to do 3:39, but
then I need it rounded to the 49 and set to show up as .75.
Any ideas would be great. Thanks--Ms Chewie


To round your time:

=ROUND((B1-A1)/TIME(0,15,0),0)*TIME(0,15,0)

With your times in A1 and B1, the above formula will show 3:45 as a result. To
show it as 3.75, you multiply by 24 (and format the result as General or as
Number with 2 decimal places):

=24*ROUND((B1-A1)/TIME(0,15,0),0)*TIME(0,15,0)


--ron