Conditional Formatting based on current time

ireland87

Board Regular
Joined
Jul 22, 2015
Messages
52
Hi

I need to have some conditional formatting based on the current time

Say A1 contains 07:00

I'd like the formatting to be green if 07:00
Orange when its 07:15
Red after 07:30

is there any way to make it flash red after 07:30 as well?

many thanks
 

Excel Facts

Do you hate GETPIVOTDATA?
Prevent GETPIVOTDATA. Select inside a PivotTable. In the Analyze tab of the ribbon, open the dropown next to Options and turn it off
Unclear.

You say you want the conditional formatting based on the current time but then you say the formatting is dependent on A1 ???
A1 will not update unless performed by VBA or manual refresh of the spreadsheet.

07:00 is 07:00 and ZERO seconds.

So "I'd like the formatting to be green if 07:00" will stay green for one second.
This is probably not what you want.

I presume what you mean is between 07:00:00 and 07:14:59 you want it to be green
Orange between 07:15:00 and 07:29:59
and red when it's 07:30:00 and after

Yes?

Select a cell to highlight

Conditional Formatting
New Rule
Use a formula to determine... (3 needed, one for each colour)

=TEXT(NOW(),"hh:mm")>"07:00" format as green
=TEXT(NOW(),"hh:mm")>"07:15" format as red
=TEXT(NOW(),"hh:mm")>"07:30" format as orange
 
Last edited:
Upvote 0

Forum statistics

Threads
1,214,913
Messages
6,122,207
Members
449,074
Latest member
cancansova

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.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

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

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

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
Back
Top