Results 1 to 6 of 6

Thread: [RESOLVED] Distinct Values

  1. #1
    Hyperactive Member
    Join Date
    Jun 10
    Posts
    371

    Resolved [RESOLVED] Distinct Values

    From VBA, can I get just the distinct values from part of a Worksheet column ?

    The part is the first 7 characters in the cell, there's always an 8th one there but that must be ignored.

    Thanks, ABB

  2. #2
    I don't do your homework! opus's Avatar
    Join Date
    Jun 00
    Location
    Good Old Europe
    Posts
    3,562

    Re: Distinct Values

    I'm sorry, English isn't my primary language, but could you be a bit more specific about "distinct values"?
    You're welcome to rate this post!
    If your problem is solved, please use the Mark thread as resolved button


    Wait, I'm too old to hurry!

  3. #3
    Hyperactive Member
    Join Date
    Jun 10
    Posts
    371

    Re: Distinct Values

    Hi Opus,

    Distinct as used in SQL.

  4. #4
    PowerPoster
    Join Date
    Dec 04
    Posts
    18,522

    Re: Distinct Values

    my guess is not

    while it is using excel, this is a straight out sql question and may be better placed in the database forum
    i do my best to test code works before i post it, but sometimes am unable to do so for some reason, and usually say so if this is the case.
    Note code snippets posted are just that and do not include error handling that is required in real world applications, but avoid On Error Resume Next

    dim all variables as required as often i have done so elsewhere in my code but only posted the relevant part

    come back and mark your original post as resolved if your problem is fixed
    pete

  5. #5
    Hyperactive Member
    Join Date
    Jun 10
    Posts
    371

    Re: Distinct Values

    OK Pete, It wasn't the best thought out question ! I was rushing something.... and in the end a simple few lines of basic ended up sorted it all.

    Thanks, ABB

  6. #6
    PowerPoster techgnome's Avatar
    Join Date
    May 02
    Posts
    21,651

    Re: Distinct Values

    If the issue is resolved, please mark the thread as such... you can do that by using the Thread Tools menu just above post #1.

    -tg
    * I don't respond to private (PM) requests for help. It's not conducive to the general learning of others.-I also subscribe to all threads I participate, so there's no need to pm when there's an update.*
    *Proof positive that searching the forums does work: View Thread *
    * How to get EFFECTIVE help: The Hitchhiker's Guide to Getting Help at VBF - Removing eels from your hovercraft *
    * How to Use Parameters * Create Disconnected ADO Recordset Clones * Set your VB6 ActiveX Compatibility * Get rid of those pesky VB Line Numbers * I swear I saved my data, where'd it run off to??? *
    * Use Offensive Programming, not Defensive Programming. * On Error Resume Next is error ignoring, not error handling(tm).
    "There is a major problem with your code, and VB wants to tell you what it is.. but you have decided to put your fingers in your ears and shout 'I'm not listening!'" - si_the_geek on using OERN

Posting Permissions

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