Conditional Formatting for two duplicates

kalcherd

New Member
Joined
Mar 19, 2011
Messages
2
Really struggle with Excel, so this might be a quick and easy one for someone out there?<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /><o:p></o:p>
<o:p> </o:p>
I want to conditional format a worksheet, which is to check for two criteria’s in two columns to capture duplications and then colour that row in the worksheet. <o:p></o:p>
<o:p> </o:p>
I can make this happen for the first check using countif to see if two numbers of the same value have been entered into column G =COUNTIF($G$2:$G$1009,$G2)>1. However, the second critera I just cannot get to work as one with 1<SUP>st</SUP>, as one countif statement.<o:p></o:p>
<o:p></o:p>
The second duplication check, is on column F which has an option of two text entries, which come from a data validation list. The two text options are FBR and TPT which has meaning to a vlookup I'm doing in column H based on the number entered in column G, returning the vlookup for the respective tabs of FBR and TPT.<o:p></o:p>
<o:p></o:p>
So I want to flag when number 1 in column G is already in the list and being used for vlookup for one tab, either FBR or TPT. Therefore I can have a number 1 as a vlookup for FBR tab & one for TPT tab, and this is not a duplicate. It's just when it the number has been entered twice for the same TAB, say FBR.<o:p></o:p>
<o:p></o:p>
Can someone help? <o:p></o:p>
 

Excel Facts

What is the last column in Excel?
Excel columns run from A to Z, AA to AZ, AAA to XFD. The last column is XFD.
Welcome to the MrExcel board!

If this is not what you want, please post back with more details and which Excel version you are using.

If Excel 2007+, select A2 to bottom right of data (A2:H10 for me) and apply the CF shown.

Excel Workbook
ABCDEFGH
1H1H2H3H4H5H6H7H8
2FBR1
3TPT2
4TPT3
52
61
7TPT2
8FBR3
9FBR1
104
11
CF 2007+
Cells with Conditional Formatting
CellConditionCell FormatStop If True
A21. / Formula is =COUNTIFS($G$2:$G$1010,$G2,$F$2:$F$1010,$F2)>1Abc




If Excel 2003-, then

Excel Workbook
ABCDEFGH
1H1H2H3H4H5H6H7H8
2FBR1
3TPT2
4TPT3
52
61
7TPT2
8FBR3
9FBR1
104
11
CF 2003-
Cells with Conditional Formatting
CellConditionCell FormatStop If True
A21. / Formula is =SUMPRODUCT(--($G$2:$G$1009=$G2),--($F$2:$F$1009=$F2),--($G$2:$G$1009<>""),--($F$2:$F$1009<>""))>1Abc
 
Upvote 0
Peter, You have cracked this for me.<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /><o:p></o:p>
What a great site this is and everyone is so lucky to have a mediator like you.<o:p></o:p>
Many thanks,<o:p></o:p>
DK<o:p></o:p>
:cool:
 
Upvote 0

Forum statistics

Threads
1,223,236
Messages
6,170,912
Members
452,366
Latest member
TePunaBloke

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