# Calculating Time Taken

#### gjohnno

##### New Member
I work for a large Logistic company who contracts most of their distribution out to another company.

This Contractor is paid on the level of delivery service required.

There are 3 levels of delivery service provided

Level 1 = 24 hours delivery

Level 2 = 3 days delivery

Level 3 = 14 days delivery

The Contractor has up till 23:59 on the 3rd or 14th Day respectively to deliver level 2 & 3 distribution

Example 1
Cell A2 Level 1
Cell B2 I have the Start Date & Time of 26 May 2008 09:47
Cell C2 I have the Finish Date & Time of 27 May 2008 07: 23

The formula I use is =IF(C2<=B2+1,"YES","NO" )

Example 2
Cell A5 Level 2
Cell B5 I have the Start Date & Time of 26 May 2008 09:47
Cell C5 I have the Finish Date & Time of 29 May 2008 07: 23

The formula I use is =IF(C5<=B5+3,"YES","NO" )

Example 3
Cell A8 Level 2
Cell B8 I have the Start Date & Time of 26 May 2008 09:47
Cell C8 I have the Finish Date & Time of 29 May 2008 12: 55

The formula I use is =IF(C8<=B8+3,"YES","NO" )

The reason why it is 'No" it is taken from the start time

Any ideas of a formula to include the extra time up till 23:59 on the 3rd or 14th day of delivery

gjohnno

### Excel Facts

How to change case of text in Excel?
Use =UPPER() for upper case, =LOWER() for lower case, and =PROPER() for proper case. PROPER won't capitalize second c in Mccartney

#### cornflakegirl

##### Well-known Member
Welcome to the board.

What you want to do is add 3 to the date, then round up the time to the end of the day. Because days are integers in Excel, you can do exactly that:

=IF(C5 < ROUNDUP(B5+3,0),"YES","NO" )

Notice the < = is changed to a < because the round up takes it to the next day at 00:00:00 - so it needs to be less than that to comply.

Replies
0
Views
195
Replies
20
Views
303
Replies
7
Views
162
Replies
10
Views
104
Replies
1
Views
96

1,191,579
Messages
5,987,428
Members
440,096
Latest member
yanaungmyint

### We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.

### Which adblocker are you using?

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

### Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

### Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back