Finding duplicate names

Gordon1963

New Member
Joined
Oct 18, 2017
Messages
18
I have a worksheet and there are company names we shouldn’t process. I have an exceptional list with those company names, so if those names appear in my worksheet, highlight those companies. Here is a sample

Exception list. New List
Lee Company. Pace
Legacy. LCMH
Abc. LCMH
LCMH. Lee Company
Legal Sea

From the example, LCMH should be highlighted twice and Lee Company once. These two companies should also be highlighted on the exception list. There will be approximately 500 exception companies and thousands on the list group. I tried Conditional formatting and if a company appears in the second column more than once, it highlighted it once.
 
There will be 2 conditional formatting formulas one for each column.
For column A, highlight the cells, and insert this formula into the conditional formatting rule.
Excel Formula:
=COUNTIF($B$2:$B$6,A2)>0
It is counting the value of A2 in column B (hence it needs to be locked). If the count is more than 0, meaning it exists, then highlight the cell. With relative reference, it will apply the rule to cells A3, A4,... and so on.

Similarly, for column B, highlight the cells, and insert.
Excel Formula:
=COUNTIF($A$2:$A$6,B2)>0
It's the same formula but the columns are swapped. It's now checking if B2 is in column A.
 
Upvote 0
Solution

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.

Forum statistics

Threads
1,223,228
Messages
6,170,876
Members
452,363
Latest member
merico17

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