You've under-described your problem, in that it's not clear if you are
looking for exactly the same text in the two cells or looking for the
same sub-string in two cells.
If it's the exact same text, use Excel's Exact function
=If(Exact(A1, B1),"I knew they were the same!", "Busted again...")
If it is the presence of a substring in two cells, things get a bit
messier, but this should work:
=IF(NOT(OR(ISERROR(FIND("OK",A1)),ISERROR(FIND("OK",B1)))),"'Twas there
all along", "Quoth the raven: Nevermore!")
or
=IF(AND(NOT(ISERROR(FIND("OK",A1))),NOT(ISERROR(FIND("OK",B1)))),"'Twas
there all along", "Quoth the raven: Nevermore!")
note that instead of having the string "OK" in the cell formulas, you
could have it in another cell - say A3 and then use A3 in the place of
"OK" in the formulas above. AND also note that Find is case-sensitive,
so you might want to throw in an UPPER() around any string or the name
of any cell that contains a string.
The latter two are pretty ugly cell formulas - it wouldn't surprise me
if someone came up with something more elegant...
Good luck! :Bgr