Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
SouthAfricanStan
 
Posts: n/a
Default Difference in two times over days

Each of A1 (time out) and E1(time returned) are in the custom format of
yyyy/mm/dd/ hh:mm
I need to calculate two results, for a car hire company:
1. The total time difference as days;hours;minutes.
Some clients are charged per day and if the vehicle is returned later than
one hour after a 24 (or multiple of 24) hour period then the client is
charged an additional full day's rate. eg if a vehicle has been used for 3
days and one hour (or less than one hour), the charge is for 3 days, but if
for 3 days and more than one hour the charge is for four days. In view of
this requirement:
2. The total time difference as days;hours
Any help will be appreciated.


  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
JE McGimpsey
 
Posts: n/a
Default Difference in two times over days

One way:

=INT(E1-A1) & " days; " & TEXT(E1-A1,"hh") & " hours"

In article ,
"SouthAfricanStan" <me@there wrote:

Each of A1 (time out) and E1(time returned) are in the custom format of
yyyy/mm/dd/ hh:mm
I need to calculate two results, for a car hire company:
1. The total time difference as days;hours;minutes.
Some clients are charged per day and if the vehicle is returned later than
one hour after a 24 (or multiple of 24) hour period then the client is
charged an additional full day's rate. eg if a vehicle has been used for 3
days and one hour (or less than one hour), the charge is for 3 days, but if
for 3 days and more than one hour the charge is for four days. In view of
this requirement:
2. The total time difference as days;hours
Any help will be appreciated.

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
difference betwwen two dates in days seven Excel Worksheet Functions 5 May 15th 06 10:01 AM
Calendar Days and Option Buttons Andy Excel Discussion (Misc queries) 0 January 10th 06 09:50 PM
I need the difference between two dates expressed as 4 years 3 mo. Dean Excel Discussion (Misc queries) 2 December 1st 05 05:11 AM
HOURS DIFFERENCE IN TIME BETWEEN DIFFERENT DATES AND TIMES tankerman Excel Worksheet Functions 1 September 13th 05 04:31 PM
Difference in Times bcbjork Excel Discussion (Misc queries) 6 August 27th 05 03:42 PM


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

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

About Us

"It's about Microsoft Excel"