Data Validation - Duplicate Entries

schang_825

Board Regular
Joined
Feb 19, 2010
Messages
66
Hi all,

I have a schedule for a move-in of a new condominium that currently does not allow for scheduling of the same unit twice. However, I want to allow the penthouse units to have multiple move-in slots. My current formula is:

=COUNTIF($D$10:$GC$30,D10)=1

How can I change it to allow the penthouse units (4601-4809) to be scheduled more than once?

Thanks!
 

Excel Facts

Select a hidden cell
Somehide hide payroll data in column G? Press F5. Type G1. Enter. Look in formula bar while you arrow down through G.
How is your data setup? What does your formula evaluate to, it looks like you want to get to a True/False value? What is in cell D10?
 
Upvote 0
Thanks for your quick response, Ryan.

I have the dates going across in Row 8, with the times going down in Column B. In D10 to GC30, the unit numbers will be entered. If a unit is scheduled twice, a message box will pop up notifying the person that this unit has already been scheduled.

What I want to modify, is if that unit is a penthouse unit (eg: unit 4803), then that unit can be entered twice. Does that help?
 
Upvote 0
Ah I see. Are you doing this through a data validation range on the rnage D10:GC30? If so, I wounder if your formula could ignore the penthouses altogether.

=OR(COUNTIF($D$10:$GC$30,D10)=1,D10=4801,D10=4802,D10=4803, D10=4804, D10=4805,D10=4806, D10=4807,D10=4808,D10=4809)

Its ugly but maybe it works?
 
Upvote 0
Thanks for your quick response! I actually figured out a solution right before reading yours:

=IF(OR(D10=4802,D10=4803,D10=4804,D10=4805,D10=4806,D10=4807,D10=4808,D10=4809),D10,COUNTIF($D$10:$GC$30,D10)=1)
 
Upvote 0

Forum statistics

Threads
1,224,595
Messages
6,179,798
Members
452,943
Latest member
Newbie4296

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