1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

VBA Code needed

Discussion in 'Business Applications' started by budward, Jan 27, 2007.

Thread Status:
Not open for further replies.
Advertisement
  1. budward

    budward Thread Starter

    Joined:
    Oct 27, 2006
    Messages:
    75
    I need a VBA code to take the list of follower numbers and separate them into tiers.
    For example, using #768, it would have to recognise that 768,678,867,876 are
    all variations of the same # and list all #'s with 4 variations first, 3 variations ,
    2 variations, and last all single #'s
    In real life I would like it to list all 6 # 's ,then 5's, then 4's,then 3's, then 2's, then singles.
    Not to start at 4 like the example.
    There could also be many more followers than in the example also.
    See example worksheet below to understand what I am trying to do.
     
  2. budward

    budward Thread Starter

    Joined:
    Oct 27, 2006
    Messages:
    75
    The example didn't upload will try again.
     
  3. budward

    budward Thread Starter

    Joined:
    Oct 27, 2006
    Messages:
    75
    Here is my second attempt.
     
  4. budward

    budward Thread Starter

    Joined:
    Oct 27, 2006
    Messages:
    75
    Here we go again. The file was too big!
     
  5. budward

    budward Thread Starter

    Joined:
    Oct 27, 2006
    Messages:
    75
    I think I got it . If not I will forget it.
     

    Attached Files:

  6. Rollin_Again

    Rollin_Again

    Joined:
    Sep 4, 2003
    Messages:
    4,912
    I'm confused by what you are trying to accomplish. In your example above there are more than 4 combinations. Will the follower numbers always be 3 digits long? If the follower number is 3 digits long and each number is unique, there will always be 6 possible combination. If two of the numbers are the same and the third is unique the will always be 3 combinations.

    768
    786
    867
    876
    687
    678


    Regards,
    Rollin
     
  7. budward

    budward Thread Starter

    Joined:
    Oct 27, 2006
    Messages:
    75
    Rollin,
    Yes, all followers will be 3 digits long. I would like to search the list of followers and then make a list of all numbers starting with all numbers with all 6 variations.
    768 786 876 876 687 678
    123 132 213 231 312 321
    etc...
    then all numbers with 5 variations
    234 243 324 342 423
    012 021 102 120 210
    etc...
    then all numbers with 4 variations
    then all numbers with 3 variations
    then all numbers with 2 variation
    and lastly all single numbers with no variations. I will attach another example that better shows how I would like them listed.
    I keep trying to upload an example but it's not working. PM me your e-mail if you want and I will I e-mail you a copy
     
  8. Rollin_Again

    Rollin_Again

    Joined:
    Sep 4, 2003
    Messages:
    4,912
    In your example above you imply that there are 5 variations to the numbers. Unless I am understanding incorrectly I see 6 variations.

    234 243 324 342 423 -----> 432
    012 021 102 120 210 -----> 201

    You can email me at Rollin_Again at hotmail dot com

    Regards,
    Rollin
     
  9. Sponsor

As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 733,556 other people just like you!

Loading...
Thread Status:
Not open for further replies.

Short URL to this thread: https://techguy.org/538934

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice