+ Reply to Thread
Results 1 to 4 of 4

Comparing values in a range

  1. #1
    Forum Contributor
    Join Date
    04-21-2007
    Location
    Lima, Peru
    MS-Off Ver
    2000, 2007, 2010
    Posts
    674

    Comparing values in a range

    I have a file which has ten columns containing randomly generated numbers, and several thousand lines.

    Each set of numbers, i.e one line, should be unique and the problem I have been having is to compare the numbers solely in VBA.

    The solution I have at present is to concatenate the numbers and then to use the find function to determine if there are any duplicates.

    I have attached a small sample and would be grateful if anyone has any ideas how it may be possible to achieve this.

    Many thanks

    Jeff
    Attached Files Attached Files

  2. #2
    Forum Contributor
    Join Date
    11-11-2005
    Posts
    267
    You can accomplish what you you have started-the concatenation idea-in VBA.

    Please Login or Register  to view this content.
    HTH
    Myles

    ...constantly looking for the smoother pebble while the whole ocean of truth lies before me.

  3. #3
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689
    Jeff,

    Here's a similar approach.
    Please Login or Register  to view this content.
    BTW, the fact that the catenations are the same doesn't mean that the rows are identical;

    12, 34

    and

    123, 4

    catenate to the same result ...
    Last edited by shg; 11-29-2007 at 01:53 AM.

  4. #4
    Forum Contributor
    Join Date
    04-21-2007
    Location
    Lima, Peru
    MS-Off Ver
    2000, 2007, 2010
    Posts
    674

    Comparing values in a range

    Thanks a lot for the advice, I will see how it all works out.

    Regarding the dulication issue, the numbers are nax 2 digit so I think that this should not be an issue as they are sorted in ascending order.

    Thanks again

    Jeff

+ 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