Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 22
Default Count the number of hours/durations



Cell A1 ---- Jan 1, 2010
Cell A2 ---- 10:58 [AM]
Cell B1 ---- Jan 3, 2010
Cell B2 ---- 22:10 [PM]

What is the formula that I can use to give me the results of no of hours
between Jan 1, 2010 at 10:58AM to Jan 3, 2010 22:10 PM?
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8
Default Count the number of hours/durations

Hi Jafferi

The following formula does the job:
=(A3-A1+A4-A2)*24

This works out precisely how many hours down to the decimal places.

If you want the number of whole hours:
=int((A3-A1+A4-A2)*24)

If you want the number of whole hours rounded to the nearest hour:
=round((A3-A1+A4-A2)*24,0)

Hope this helps.

David


"Jafferi" wrote:



Cell A1 ---- Jan 1, 2010
Cell A2 ---- 10:58 [AM]
Cell B1 ---- Jan 3, 2010
Cell B2 ---- 22:10 [PM]

What is the formula that I can use to give me the results of no of hours
between Jan 1, 2010 at 10:58AM to Jan 3, 2010 22:10 PM?

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,533
Default Count the number of hours/durations

Hi

Use this formula and format the formla cell a Custom [h]:mm

=B1-A1+(B2-A2)

Regards,
Per

"Jafferi" skrev i meddelelsen
...


Cell A1 ---- Jan 1, 2010
Cell A2 ---- 10:58 [AM]
Cell B1 ---- Jan 3, 2010
Cell B2 ---- 22:10 [PM]

What is the formula that I can use to give me the results of no of hours
between Jan 1, 2010 at 10:58AM to Jan 3, 2010 22:10 PM?


  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 806
Default Count the number of hours/durations

Hello,

I suggest to use my UDF count_hours:
http://sulprobil.com/html/count_hours.html

Regards,
Bernd
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Count hours dr Dave08 New Users to Excel 2 October 15th 08 12:24 PM
Converting total number of hours (24 hours) into days MV Rao Excel Discussion (Misc queries) 1 January 24th 08 12:50 PM
Count hours per month Derek Excel Worksheet Functions 3 September 19th 07 11:52 AM
durations chad Excel Discussion (Misc queries) 5 May 30th 07 02:33 PM
wages - multiply hours and minutes by number of hours worked Carol (Australia) Excel Discussion (Misc queries) 6 April 1st 07 01:16 AM


All times are GMT +1. The time now is 12:35 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"