ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   two data validations for same cell (https://www.excelbanter.com/excel-discussion-misc-queries/133133-two-data-validations-same-cell.html)

dandiehl

two data validations for same cell
 
I would like to perform two unique validation on the same cell. For
instance, I would like to ensure the cells A1:A10 only contain 10 digits
(phone number) and also that there are no duplicates in the range.

Can this be done?

Elkar

two data validations for same cell
 
Yes, this can be done. Change the Allow field to "Custom" Enter the
following formula:

=AND(LEN(A1)=10,COUNTIF($A$1:$A$10,A1)=1)

HTH,
Elkar


"dandiehl" wrote:

I would like to perform two unique validation on the same cell. For
instance, I would like to ensure the cells A1:A10 only contain 10 digits
(phone number) and also that there are no duplicates in the range.

Can this be done?



All times are GMT +1. The time now is 08:34 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com