Changing the color of a cell based on a formula.

Zac

Well-known Member
Joined
Feb 20, 2002
Messages
796
In O15 I will have either of the following:
=Max(R15:AM15)
=Min(R15:AM15)

I have a button with a Macro attached that
let's us change from Max to MIN.

In Cell O8 I would like to have "MIN"
In Cell O9 I would like to have "MAX"
Is there a way to highlite either O8 or O9
with a colored background or Text alerting the user which formula is activated?

Maybe by using the Left (Fx) to view the 4
LEFT characters of O15 or something like that.

Any other ideas would be acceptable also.

As always Thanks for U R help,
Mike
 

Excel Facts

Move date out one month or year
Use =EDATE(A2,1) for one month later. Use EDATE(A2,12) for one year later.
Could this work????? Just changing O8 to a conditional formula that changes to "MIN" or MAX", based on the value of O15???

=IF(O15=MIN(R15:AM15),"MIN","MAX")

If not, yell and I'll play some more
 
Upvote 0
Tried the following :

=IF(O15=Min(R15:AM15),"Min","Max")

It worked when the formula was Min, but
it didn't change to Max when the formula wasn't Min(.......). In this case it was Max(.....).

Any other suggestions.

Zac
 
Upvote 0
If the formula in cell O15 changes from Min to Max when you click your Macro button, then this should work and cell O8 will change from "Min" to "Max" as well....if not, there is a typo, or i don't quite understand what is in cell O15.
 
Upvote 0
O15 has a resulting Numerical value based
on what is pulled in by the Min and Max formula.

=IF(O15=MIN(R15:AM15),"MIN","MAX")

Again when I hit the button to change the reqmnt from Min to MAX.
Min shows up in O8. Always.

I'm baffled.. I know it should work too, but it doesn't.

HELP.
 
Upvote 0

Forum statistics

Threads
1,213,501
Messages
6,114,010
Members
448,543
Latest member
MartinLarkin

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