Link to home
Start Free TrialLog in
Avatar of Patrick de Gelder
Patrick de GelderFlag for Netherlands

asked on

COUNTIF command in Microsoft excel 2010

Standard excel document with 2 sheets in office 2010
How can 2 rows be compare and highlight the values, when the value shows in both list.

Example
Sheet 1 | Sheet 2

A               A
1234         4324
2222         3338
3333         1234
4444         4556

Now I excel need to automatically highlight the value 1234 because it show in both rows.
Current I try to get this done by using the COUNTIF statement

=COUNTIF(sheet1!$A$2:$A$3,A2)>1

As soon I hit enter I got an error message, the formula you typed in contains an error.
test.xlsx
Avatar of Norie
Norie

I don't see anything wrong with the formula.

Where are you using the formula?
Avatar of Patrick de Gelder

ASKER

Standard edition from Microsoft excel 2010,

First selected column A on sheet 2, then I go to the option conditional formatting, then fill in the formula and selected a specific color and as soon I click on it reports the above error.
Does the formula work if you enter it on a worksheet?
No have tried that any other statement seems to work fine
ASKER CERTIFIED SOLUTION
Avatar of Norie
Norie

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thanks, you help me a lot,
It's very strange it must be a problem with office I checked the formula in your sheet and it works well :). Then in a new empty document same formula it doesn't work.
But then there is no reason to troubleshoot this further as this pc is going soon anyway.

For further reference we confirmed that the formula works. :-)
Thanks for helping get this problem fixed