Jurassic_Sparks
New Member
- Joined
- Apr 9, 2014
- Messages
- 2
Hello
I've searched a lot for the answer to my problem but with no success so far; please accept my apologies if something like this has been posted before.
I'm not entirely sure how to word this question, so it might be easier to give you an example from my spreadsheet.
I have a very simple worksheet that calculates the finish time of a movie based on a user-inputted start time, and running time. Using a simple IF formula and conditional formatting, it displays the start and finish time of each movie along with the colour-coded duration, in a sort of bar chart sort of way.
The problem that I'm having is that the formula/conditional formatting doesn't seem to work for about 20 given time-slots. Ignoring the conditional formatting for now (it uses the same IF formula), the example below shows the problem that I am having getting the finish times to be displayed.
Cell A2 is the Running Time
enter the number of minutes, e.g. 80
Cell B2 is the Start Time
enter the start time e.g. 19:00
Cells C1, D1 and E1 are the example Time-Slots
Cell C1 enter 20:20
Cell D1 enter 20:25
Cell E1 enter 20:30
Cell F2 converts the Running Time into a decimal
enter the formula =A2/1440
Cell G2 is the Finish Time and is calculated by adding the decimalised Running Time to the Start Time
enter the formula = F2+B2
Cells C2, D2 and E2 each check if the Finish Time is the same as the Time-Slot. If it is the same, the Finish Time is displayed. If it isn't the same, the cell remains blank
Cell C2 enter the formula =IF(G2=C1,C1,"")
Cell D2 enter the formula =IF(G2=D1,D1,"")
Cell E2 enter the formula =IF(G2=E1,E1,"")
Using the above example, you should find that 20:20 is correctly displayed in cell C2, below the corresponding 20:20 Time-Slot.
Now change the Running Time in cell A2 to 90 minutes. You will find that 20:30 is correctly displayed in cell E2.
However, change the Running Time to 85 minutes. No Finish Time appears; D2 remains blank.
My spreadsheet is set up in 5-minute increments from 10am to midnight and the following time-slots also do not appear to work:
16:20 / 16:35 / 17:05 / 17:25 / 17:50 / 18:10 / 18:35 / 18:55 / 19:20 / 19:40 / 20:05 / 20:25 / 20:50 / 21:10 / 21:35 / 21:55 / 22:20 / 22:40 / 23:05 / 23:25 / 23:50
Every other time-slot does, just not these.
If I manually type the finish time over the formula in cell G2, everything works properly, but as soon as I put the formula back in it stops working for the above time-slots.
I have checked every single cell to make sure that they are formatted correctly, and as I say, the formula works exactly how I want it to, except for the above time-slots. I am at a loss to think why this group of seemingly random times would stop the formula from working.
Can anyone think why this might be occurring or maybe there is a simple workaround that someone can think of?
I am using Excel 2010 on Windows 7.
Thanks in advance for any help you might be able to offer.
I've searched a lot for the answer to my problem but with no success so far; please accept my apologies if something like this has been posted before.
I'm not entirely sure how to word this question, so it might be easier to give you an example from my spreadsheet.
I have a very simple worksheet that calculates the finish time of a movie based on a user-inputted start time, and running time. Using a simple IF formula and conditional formatting, it displays the start and finish time of each movie along with the colour-coded duration, in a sort of bar chart sort of way.
The problem that I'm having is that the formula/conditional formatting doesn't seem to work for about 20 given time-slots. Ignoring the conditional formatting for now (it uses the same IF formula), the example below shows the problem that I am having getting the finish times to be displayed.
Cell A2 is the Running Time
enter the number of minutes, e.g. 80
Cell B2 is the Start Time
enter the start time e.g. 19:00
Cells C1, D1 and E1 are the example Time-Slots
Cell C1 enter 20:20
Cell D1 enter 20:25
Cell E1 enter 20:30
Cell F2 converts the Running Time into a decimal
enter the formula =A2/1440
Cell G2 is the Finish Time and is calculated by adding the decimalised Running Time to the Start Time
enter the formula = F2+B2
Cells C2, D2 and E2 each check if the Finish Time is the same as the Time-Slot. If it is the same, the Finish Time is displayed. If it isn't the same, the cell remains blank
Cell C2 enter the formula =IF(G2=C1,C1,"")
Cell D2 enter the formula =IF(G2=D1,D1,"")
Cell E2 enter the formula =IF(G2=E1,E1,"")
Using the above example, you should find that 20:20 is correctly displayed in cell C2, below the corresponding 20:20 Time-Slot.
Now change the Running Time in cell A2 to 90 minutes. You will find that 20:30 is correctly displayed in cell E2.
However, change the Running Time to 85 minutes. No Finish Time appears; D2 remains blank.
My spreadsheet is set up in 5-minute increments from 10am to midnight and the following time-slots also do not appear to work:
16:20 / 16:35 / 17:05 / 17:25 / 17:50 / 18:10 / 18:35 / 18:55 / 19:20 / 19:40 / 20:05 / 20:25 / 20:50 / 21:10 / 21:35 / 21:55 / 22:20 / 22:40 / 23:05 / 23:25 / 23:50
Every other time-slot does, just not these.
If I manually type the finish time over the formula in cell G2, everything works properly, but as soon as I put the formula back in it stops working for the above time-slots.
I have checked every single cell to make sure that they are formatted correctly, and as I say, the formula works exactly how I want it to, except for the above time-slots. I am at a loss to think why this group of seemingly random times would stop the formula from working.
Can anyone think why this might be occurring or maybe there is a simple workaround that someone can think of?
I am using Excel 2010 on Windows 7.
Thanks in advance for any help you might be able to offer.