+ Reply to Thread
Results 1 to 5 of 5

Possible Vlookup Funtion - Determine Age Group By Date Range

  1. #1
    Registered User
    Join Date
    04-20-2012
    Location
    Tampa
    MS-Off Ver
    Excel 2007
    Posts
    12

    Possible Vlookup Funtion - Determine Age Group By Date Range

    Hey All,

    I've been trying to figure this out for the longest and I'm about to pull out my hair.

    Here is what I'm trying to accomplish.

    I'm creating a Soccer Roster and i want to determine what age group each child should be in.
    e.g
    if there birthday is between
    8/1/2001 - 7/31/2002 they would be U11
    8/1/2002 - 7/31/2003 they would be U10
    8/1/2003 - 7/31/2004 they would be U9
    8/1/2004 - 7/31/2005 they would be U8

    I have read in some places and VLookup seems to be the way to do this, but I have tried it several times and
    I can't get the range to work.

    if I put 8/1/2001 it tells me they are U11, BUT, if I put 8/15/2001 it errors out and comes up with NA

    Any help would greatly be appreaciated

    thanks

    DM

  2. #2
    Forum Expert DGagnon's Avatar
    Join Date
    02-23-2012
    Location
    Ontario, Canada
    MS-Off Ver
    Excel 2003, 2007
    Posts
    1,645

    Re: Possible Vlookup Funtion - Determine Age Group By Date Range

    if you create a range that has these values in it:

    ---a---- ---b----
    8/1/2000 Too Old
    8/1/2001 U11
    8/1/2002 U10
    8/1/2003 U9
    8/1/2004 U8
    8/1/2005 Too Young

    you can use a formula like this:
    =VLOOKUP(D1,A:B,2,1)

    See Attachement
    Attached Files Attached Files
    If you liked my solution, please click on the Star -- to add to my reputation

    If your issue as been resolved, please clearly state so and mark the thread as [SOLVED] using the thread tools just above the first post.

  3. #3
    Registered User
    Join Date
    04-20-2012
    Location
    Tampa
    MS-Off Ver
    Excel 2007
    Posts
    12

    Re: Possible Vlookup Funtion - Determine Age Group By Date Range

    Thank you, this seemed to have worked, but I am having the following problem,

    it works on the first few but when i click on the cell and double click on it so that it can replicate down to the rest of the cells, the 1st 5 work then I get a whole bunch of NA's.

    any ideas why this is happening?

    Am I supposed to lock the cells for the table?

  4. #4
    Forum Expert DGagnon's Avatar
    Join Date
    02-23-2012
    Location
    Ontario, Canada
    MS-Off Ver
    Excel 2003, 2007
    Posts
    1,645

    Re: Possible Vlookup Funtion - Determine Age Group By Date Range

    it should work... i referenced the full columns, but you could try that

    =VLOOKUP(D1,$A:$B,2,1)

    if its still not working, try attaching a workbook with some examples.

  5. #5
    Registered User
    Join Date
    04-20-2012
    Location
    Tampa
    MS-Off Ver
    Excel 2007
    Posts
    12

    Re: Possible Vlookup Funtion - Determine Age Group By Date Range

    Awesome, that did it, I have another question, I just posted, maybe you can take a peek

    thanks again

+ 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