ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   formula to calulate length of time (https://www.excelbanter.com/excel-worksheet-functions/65145-formula-calulate-length-time.html)

Lynda S

formula to calulate length of time
 
I need to create a formula that displays the length of stay between to dates
in a cell. For example the length of time between date 1 = 2006/01/06 12:30
pm and date 2 = 2006/01/13 10:30 am. What is the time frame here in hours.

Niek Otten

formula to calulate length of time
 
=A2-A1
FormatCells, Number tab, Custom. In the Type box, enter [h]
in your case the result is 166 hours

--
Kind regards,

Niek Otten

"Lynda S" <Lynda wrote in message
...
I need to create a formula that displays the length of stay between to
dates
in a cell. For example the length of time between date 1 = 2006/01/06
12:30
pm and date 2 = 2006/01/13 10:30 am. What is the time frame here in
hours.




Sloth

formula to calulate length of time
 
=24(A2-A1)

format as a number.

"Lynda S" wrote:

I need to create a formula that displays the length of stay between to dates
in a cell. For example the length of time between date 1 = 2006/01/06 12:30
pm and date 2 = 2006/01/13 10:30 am. What is the time frame here in hours.


Lynda S

formula to calulate length of time
 
Thank you very much. This is exactly what l was looking for

Lynda S

"Lynda S" wrote:

I need to create a formula that displays the length of stay between to dates
in a cell. For example the length of time between date 1 = 2006/01/06 12:30
pm and date 2 = 2006/01/13 10:30 am. What is the time frame here in hours.



All times are GMT +1. The time now is 10:31 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com