custom function with conditional formatting?

  • Thread starter Thread starter Steve
  • Start date Start date
S

Steve

I often have to test a large number of cells to see if they're equal. I
usually use a-b or =a=b and check if the answer is either zero or true. If
not I know they're not equal. It would be nice if I could do this with a
custom formula that would also turn the background red, for example, if the
answer isn't either zero or true.

I doubt this can be accomplished with a custom formula, though, since
formulas are meant to return values, not "do something".
 
You can use formulae in conditonal formatting by selecting Formula Is
rather than Cell Value Is in the first dialogue box. However, in your
case you can just use Cell Value Is then Equal to then zero and set
the format you want. If you do this on the first cell with that
formula, then when you copy it down it will apply to all cells.

Hope this helps.

Pete
 
Steve said:
I often have to test a large number of cells to see if they're equal. I
usually use a-b or =a=b and check if the answer is either zero or true. If
not I know they're not equal. It would be nice if I could do this with a
custom formula that would also turn the background red, for example, if the
answer isn't either zero or true.

I doubt this can be accomplished with a custom formula, though, since
formulas are meant to return values, not "do something".
 
Format > Conditional Formatting
If you need to see if column B is equal to column A, and mark column Bi if
is NOT equal, then: in B1 (if data begins there) do conditional formatting as
follows and then copy to entire column
Cell Value Is Not Equal to A1 and change format to anything you like (red
font or red background, etc)
 
I already know how to do conditional formatting.

Karin said:
Format > Conditional Formatting
If you need to see if column B is equal to column A, and mark column Bi if
is NOT equal, then: in B1 (if data begins there) do conditional formatting as
follows and then copy to entire column
Cell Value Is Not Equal to A1 and change format to anything you like (red
font or red background, etc)
 
Back
Top