View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.misc
Jim Thomlinson Jim Thomlinson is offline
external usenet poster
 
Posts: 5,939
Default Conditional Formating - formula not working

Why not just clean up your vlookup formula so that it no longer returns #NA.
You can do that with an if statement and either CountIf or ISNA something
like this...

=if(countif(A2:A10, A1)= 0, "Not found", vlookup(A1, A2:B10, 2, False))
or
=if(ISNA(vlookup(A1, A2:B10, 2, False)), "Not Found", vlookup(A1, A2:B10, 2,
False))
--
HTH...

Jim Thomlinson


"EagleOne" wrote:

2003

Cell A1 = 101
Cell B1 = 101
Cell C1 = #N/A (Unsuccessful VLookup)

What I want (CF background color of A1 = Red) if EITHER B1 or C1 does
not equal A1

The actual not-working formula in A1 Conditional Format is:
Formula is =OR(A1<B1,A1<C1) Then Set Background Color to Red

Thanks EagleOne