View Single Post
  #9   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Mike Mike is offline
external usenet poster
 
Posts: 3,101
Default Conditional formatting comparing times

All the suggestions everyone has given are good. But, the situation I have
seems to be a little more complicated, let me explain.

The two cells I am comparing are linked to another worksheet, so I cannot
copy down otherwise I lose the link.

Cell A is 3:01 AM, B is 2:14 AM in this case cell B is =29 minutes before
cell A and cell B needs to be shaded an unique color.
If cell B is <=29 after cell A then shad then cell B is shaded a different
color.
Both Cell A and B are linked to another worksheet so I cannot put a formual
in them and I need to use Conidtional Formatting.

But I cannot get it to work.

All you suggestions do work with different situations.

Any clue on my particular need?

Thanks again.
--
Mike


"xlmate" wrote:

One suggestion,
instead of having your formula in the Conditional Formatting,
why not place the formula =(D5-B5)*1440 in cell eg. E5, and copy down

Then go to Condirional Formatting
In Condition 1 :
1) choose Cell Value Is,
2) select greater than or equal to
3) type 29
4) Click Format and select your format and color, click Ok
5) Click Add button for the next condition
Repeat the same for condition of <=29

HTH



--
Pls provide your feedback by clicking the Yes button below if this post have
help you. This will help others to search the archives for result better.


Thank You

cheers, francis









"Mike" wrote:

Thanks for responding. Still is not working so here is a further explanation.

Current Time is 6:20 AM and Previous Time is 5:44 AM. In this scenario, the
current time is <=-29 minutes after the previous time, so I want to shad the
previous time blue. Another scenario, current time 6:20 AM, previous time
6:51 AM. In this case the current time is =29 minutes before the previous
time and shad will be red.

I have tried to convert the times into minutes (D5-B5)*1440=29. This works
inconsistently. I can manually look at the times and shad them but I am
trying to automate as much as possible.

Thanks again and appreciate any help.
--
Mike


"xlmate" wrote:

Hi

I am not sure how you can arrive ot < 29 if you formatted into h:mm
the maximum for a day is 24hrs.

Would you provide a sample data table and your expected result

HTH
--
Pls provide your feedback by clicking the Yes button below if this post have
help you. This will help others to search the archives for result better.


Thank You

cheers, francis









"Mike" wrote:

I need to compare a current production release time (that will vary between
regions) to previous months release times by region.
If the difference is 29 or greater shad the cell blue.
If the difference is -29 or greater shad the cell red.

I have tried these approaches in the but get inconsisted results.
Condition 1 Formula is where D5 is the previous release time and B5 is the
current.
=(D5-B5)*144029
Condition 2 Formula is where D5 is the previous release time and B5 is the
current.
=(D5-B5)*1440<-29

The cells are formatted h:mm AM/PM and I need to keep this format for
reporting purposes.

Appreciate any help.

Thanks,

--
Mike