+ Reply to Thread
Results 1 to 19 of 19

Finding duplicate across many sheets

Hybrid View

  1. #1
    Registered User
    Join Date
    05-25-2007
    Location
    Egypt
    MS-Off Ver
    2010
    Posts
    33

    Post Finding duplicate across many sheets

    Dear Sir

    I have an excel file (in the attachmenT) that contains many numbers of sheets which contains a lot of data. I want to make sure that there is no data duplication across sheets.
    Attached Files Attached Files

  2. #2
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,259

    Re: Finding duplicate across many sheets

    Hello hero96559,

    You need to be more specific about what data you want to check. You did not include any examples in either your post or the attached workbook.
    Sincerely,
    Leith Ross

    Remember To Do the Following....

    1. Use code tags. Place [CODE] before the first line of code and [/CODE] after the last line of code.
    2. Thank those who have helped you by clicking the Star below the post.
    3. Please mark your post [SOLVED] if it has been answered satisfactorily.


    Old Scottish Proverb...
    Luathaid gu deanamh maille! (Rushing causes delays!)

  3. #3
    Registered User
    Join Date
    05-25-2007
    Location
    Egypt
    MS-Off Ver
    2010
    Posts
    33

    Re: Finding duplicate across many sheets

    Dear Sir,

    The attached workbook contains many sheets and every sheet contains serial numbers. I want to make sure that there is no duplicate serials across the sheets.. For example:

    In Hall 1 column F7 there is a serial 3CQ033B3RR. I want to make sure that these serial isn't duplicated in other sheets.

  4. #4
    Forum Contributor
    Join Date
    04-03-2011
    Location
    India
    MS-Off Ver
    Excel 2015
    Posts
    122

    Re: Finding duplicate across many sheets

    evrysheet having duplicates

  5. #5
    Registered User
    Join Date
    05-25-2007
    Location
    Egypt
    MS-Off Ver
    2010
    Posts
    33

    Re: Finding duplicate across many sheets

    Ok. In other words if i Have a number like 25486 inside sheet 1. And suppose that i write the same number again inside sheet 2. In this moments i need the program to alert me that there is another number with the same value in sheet 1. Thats all

  6. #6
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,259

    Re: Finding duplicate across many sheets

    Hello hero96559,

    Do you want to validate entries in a specific column or columns across all sheets?
    Checking all sheets anytime any cell is changed will slow your data entry down.
    I assume headers would not be included in the validation, correct?

  7. #7
    Registered User
    Join Date
    05-25-2007
    Location
    Egypt
    MS-Off Ver
    2010
    Posts
    33

    Re: Finding duplicate across many sheets

    Yes, Header would not be included

  8. #8
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,259

    Re: Finding duplicate across many sheets

    Hello hero96559,

    Are you only interested in being notified if the serial number is duplicated?
    Is there only one sheet used for input?

  9. #9
    Registered User
    Join Date
    05-25-2007
    Location
    Egypt
    MS-Off Ver
    2010
    Posts
    33

    Re: Finding duplicate across many sheets

    Yes, I need to be notified. And all the sheets used for input data

  10. #10
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,259

    Re: Finding duplicate across many sheets

    Hello hero96559,

    The solution I am working on is creating a "Master List" worksheet of serial numbers. Whenever an entry is made in any cell then it can be checked quickly for duplication. So, this process is going to take awhile to complete. It may be a few hours before I finish.

  11. #11
    Registered User
    Join Date
    05-25-2007
    Location
    Egypt
    MS-Off Ver
    2010
    Posts
    33

    Re: Finding duplicate across many sheets

    Many thanks for your interest.

  12. #12
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,259

    Re: Finding duplicate across many sheets

    Hello hero96559,

    The attached workbook validates any input in any cell against the "Serial Number" list in the "Master List" worksheet. There is an issue I need to workout. Serial numbers with a leading zero have to be input as a text value or the leading zero will not be retained. Since all the data in the "Serial Number" list is text. The other issue is how to update the "Master List". Perhaps you have some ideas about that. Otherwise, it works well.

    Here is the macro to look up the serial numbers.
    Private Sub Workbook_SheetChange(ByVal Sh As Object, ByVal Target As Range)
    
        Dim Match As Range
        Dim Rng As Range
        Dim RngEnd As Range
        Dim SN As Variant
        
            If Target.Cells.Count > 1 Then Exit Sub
            If Target.Value = "" Then Exit Sub
            
            Application.Calculation = xlCalculationManual
            Application.EnableEvents = False
        
            With Worksheets("Master List")
                Set Rng = .Range("A2")
                Set RngEnd = .Cells(Rows.Count, "A").End(xlUp)
                Set Rng = .Range(Rng, RngEnd)
                For Each SN In Rng.Value
                    If SN = Target.Text Then
                        MsgBox "The Serial Number '" & Target.Text & "' has already been Entered.", vbOKOnly + vbExclamation
                        Exit For
                    End If
                Next SN
            End With
            
            Application.Calculation = xlCalculationAutomatic
            Application.EnableEvents = True
            
    
    End Sub
    Attached Files Attached Files

  13. #13
    Registered User
    Join Date
    05-25-2007
    Location
    Egypt
    MS-Off Ver
    2010
    Posts
    33

    Re: Finding duplicate across many sheets

    FYI,I suppose to use all cell formating as text nothing else.

  14. #14
    Registered User
    Join Date
    05-25-2007
    Location
    Egypt
    MS-Off Ver
    2010
    Posts
    33

    Re: Finding duplicate across many sheets

    Sir, I still enter data with same value and no alarm

  15. #15
    Forum Moderator Leith Ross's Avatar
    Join Date
    01-15-2005
    Location
    San Francisco, Ca
    MS-Off Ver
    2000, 2003, & 2010
    Posts
    23,259

    Re: Finding duplicate across many sheets

    Hello hero96559,

    Everything is working fine with no problems or not?

  16. #16
    Registered User
    Join Date
    05-25-2007
    Location
    Egypt
    MS-Off Ver
    2010
    Posts
    33

    Re: Finding duplicate across many sheets

    it isn't working sir

  17. #17
    Registered User
    Join Date
    03-26-2012
    Location
    India
    MS-Off Ver
    excel 2007
    Posts
    21

    Re: Finding duplicate across many sheets

    Hi hero96559 2 questions
    1. I am assuming that you need to validate only serial numbers for duplication not other entries?
    2. There is log sheets like "Faulty log CUTE" where I guess its desirable to have duplicate values (serial numbers present in other sheets) pl. clarify?

  18. #18
    Registered User
    Join Date
    05-25-2007
    Location
    Egypt
    MS-Off Ver
    2010
    Posts
    33

    Re: Finding duplicate across many sheets

    Dear Leith

    You can
    Last edited by hero96559; 03-28-2012 at 08:41 AM.

  19. #19
    Registered User
    Join Date
    05-25-2007
    Location
    Egypt
    MS-Off Ver
    2010
    Posts
    33

    Re: Finding duplicate across many sheets

    Dear Leith

    You can exclude all sheets started by (fault log...). i am in no need to check duplication inside them.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1