+ Reply to Thread
Results 1 to 5 of 5

Area Code Look up

Hybrid View

  1. #1
    Registered User
    Join Date
    12-05-2012
    Location
    Maine
    MS-Off Ver
    Excel 2010
    Posts
    2

    Cool Area Code Look up

    Hi all, I'm trying to figure out how to formulate cells so that when I copy paste a list of area codes, the appropriate state shows up. I.e. paste in area code 617 and MA shows up instead of 617. Any thoughts?

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,946

    Re: Area Code Look up

    if your codes are on column A and the states in column B, use something like this...

    =vlookup(A1,$B$1:$B$100,2,false)
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  3. #3
    Registered User
    Join Date
    12-05-2012
    Location
    Maine
    MS-Off Ver
    Excel 2010
    Posts
    2

    Re: Area Code Look up

    I got #N/A

  4. #4
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,318

    Re: Area Code Look up

    What did you use that gave you #N/A?

    What you were given may need to be expand to cover all the range.

    =vlookup(A1,$B$1:$B$100,2,false)

    This will look at A1 and find a match in the second column, but if you are only referencing column B then there is no second column.
    HTH
    Regards, Jeff

  5. #5
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,946

    Re: Area Code Look up

    you may need to extend the range, too. I just used down to row 100 as an example

+ 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