Data validation formula to prevent duplicates in any cell across multiple columns

hyd1956

New Member
Joined
Jun 26, 2020
Messages
49
Office Version
  1. 365
  2. 2016
Platform
  1. Windows
Hi

I'm trying to prevent duplicates from being entered into any cell in multiple columns and across any row, the formulas I've been trying haven't worked. This is what I'm using, is there anyway to do this? thanks for thelp

=COUNTIFS($B$2:$B$6000,$B2,$D$2:$D$6000,$D2,$F$2:$F$6000,$F2)<=1
 

Excel Facts

Which came first: VisiCalc or Lotus 1-2-3?
Dan Bricklin and Bob Frankston debuted VisiCalc in 1979 as a Visible Calculator. Lotus 1-2-3 debuted in the early 1980's, from Mitch Kapor.
See if this one works (applied with B2 as the active cell).

=COUNTIFS($B$2:$B$6000,B2,$D$2:$D$6000,B2,$F$2:$F$6000,B2)=1
 
Upvote 0
Unfortunately that hasn't worked. When trying to use that formula it's not allowing me any data entry into the cells at all
 
Upvote 0
Not sure what I was thinking there, that formula was never going to work :oops: try this one instead

=(COUNTIF($B$2:$B$6000,B2)+COUNTIF($D$2:$D$6000,B2)+COUNTIF($F$2:$F$6000,B2))=1
 
Upvote 0
Hi! I have a similar situation, but when I recreate that formula using the cell ranges for my data, it does not work. I want to prevent a duplicate entry that is dependent on column C (name), D (email), and L (activity) in which the same person/email cannot be entered for the same activity.

Any thoughts are greatly appreciated!
 
Upvote 0
Maybe this applied as validation rule to C2, then copied to the other rows / columns to be validated as needed.

=(COUNTIFS($C:$C,$C2,$D:$D,$D2,$L:$L,$L2)=1
 
Upvote 0
Thank you for the reply. The formula above does not work.
 
Upvote 0
Does not work in what way?

Allows duplicates to be entered?
Does not allow anything to be entered?
Something else?
 
Upvote 0
Sorry. It allows for duplicate entries to be typed into all of the cells used in the formula.
 
Upvote 0

Forum statistics

Threads
1,213,487
Messages
6,113,943
Members
448,534
Latest member
benefuexx

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