How to write only Unique Data in Column or Range

3 views
Skip to first unread message

Ashu K

unread,
Aug 14, 2015, 6:30:06 AM8/14/15
to Excel VBA Lab
Dear Seniors,

I want to put only Unique Names in Column A. If duplicate Name was wrote by me then It will showing Error Message.

I want prevent to do the duplicate entries.



Kindly help.



Regards
Ashu Kenith

Ashish Bhalara

unread,
Aug 14, 2015, 7:28:52 AM8/14/15
to Excel VBA Lab
Hi Ashu K,

See the attached file for your query.

To get error message on entry of duplicate value you can use below condition in data validation.
 Select range of A column, Press Alt+D+L, select Custom menu, paste formula of =COUNTIF($A$1:A2,A2)<=1 in formula field.

Another way to get message on duplicate data entry, use formula of-
=IF(COUNTIF($A$2:A3,A2)>1,"DATA ALREADY EXIST IN RANGE","")

Regards
Ashish Bhalara

--
www.ExcelVbaLab.com
---
You received this message because you are subscribed to the Google Groups "Excel VBA Lab" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ExcelVbaLab...@googlegroups.com.
To post to this group, send email to Excel...@googlegroups.com.
Visit this group at http://groups.google.com/group/ExcelVbaLab.
To view this discussion on the web visit https://groups.google.com/d/msgid/ExcelVbaLab/6b5c2f8e-56c0-458a-88bd-340a0b545308%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Unique Data in Column.xls

Ashu K

unread,
Aug 14, 2015, 9:20:13 AM8/14/15
to Excel VBA Lab
Dear Ashish Bhalara Sir,

Thank you so much for your help.


Regards
Ashu Kenith
Reply all
Reply to author
Forward
0 new messages