• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Cross Posted - Find duplicate in all sheets when pasting values

ashish mehra

Active Member
Hi all,

This is a cross posted thread & link is http://www.excelforum.com/excel-programming-vba-macros/1093778-duplicate-detection.html

I hope I am not violating rules.;)

I want to setup a code in such a way that whenever I tried to copy the data the macro should check all the sheets & if found exact then it should stop me if data is new then macro should not stop me from pasting the data.

e.g. there are some codes exist in various sheets; when some one try to paste new data then vba code should check for duplicate data. I do want any duplicate data in my workbook.

How can I avoid duplication as soon as I paste the data?

Regards,
AM:)
 

Hi !

You can't avoid but you can use an event code Worksheet_Change in
worksheet module or Workbook_SheetChange in ThisWorkbook module
using RemoveDuplicates method for example (must see VBA help),
depends on worksheet data design …
 
Back
Top