+ Reply to Thread
Results 1 to 7 of 7

Auto fill county based on zip or city

  1. #1
    Registered User
    Join Date
    08-12-2015
    Location
    us
    MS-Off Ver
    not sure
    Posts
    4

    Auto fill county based on zip or city

    I have a spreadsheet of people including zip code, city, and county. Some counties are blank. How do I auto fill the county based on either the zip (first 4 digits of a zip +4 field) or the city? Sometimes we have city and no zip. For only blank fields, can I first check zip field, then use city to auto fill county? I have a master zip code and county reference file.

    I understand vlookup can do this, but I'm not a programmer and don't know how to set this up, syntax etc.

    Can anyone help?

  2. #2
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Auto fill county based on zip or city

    Hi newtbee,

    Welcome to the Forum! A dictionary for Zips with def being County and a dictionary for counties with def being Zip-4 occurs to me

    Attach a sample workbook. Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and use the paperclip icon to open the upload window.

    View Pic
    If I've helped you, please consider adding to my reputation - just click on the liitle star at the left.

    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~(Pride has no aftertaste.)

    You can't do one thing. XLAdept

    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~aka Orrin

  3. #3
    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,944

    Re: Auto fill county based on zip or city

    Attached is a (relatively) new zip code/city/state listing. You coul use this in a VLOOKUP or INDEX/MATCH to pull in the data you need.

    If you need help with this, upload a small (clean) sample workbook (not a pic) of what you are working with, and what your expected outcome would look like.
    Attached Files Attached Files
    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

  4. #4
    Registered User
    Join Date
    08-12-2015
    Location
    us
    MS-Off Ver
    not sure
    Posts
    4

    Re: Auto fill county based on zip or city

    Sample attached
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    08-12-2015
    Location
    us
    MS-Off Ver
    not sure
    Posts
    4

    Re: Auto fill county based on zip or city

    I uploaded a sample.

  6. #6
    Registered User
    Join Date
    08-12-2015
    Location
    us
    MS-Off Ver
    not sure
    Posts
    4

    Re: Auto fill county based on zip or city

    Thanks xladept . I uploaded the sample. Can anyone help w/the formula?

  7. #7
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Auto fill county based on zip or city

    Hi newtbee,

    I was expecting a list of counties cities and zip codes as well as your worksheet

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Auto fill cells based if there is something there or not
    By TlgKill in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 08-09-2013, 04:42 PM
  2. [SOLVED] Auto fill based on first digit.
    By rjlchef in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 06-18-2013, 10:20 AM
  3. [SOLVED] Zip code data that populates the city and county.
    By HeathHarlan in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 11-13-2012, 03:38 PM
  4. Auto Fill Based on other sheet
    By BlastRanger in forum Excel General
    Replies: 2
    Last Post: 09-24-2010, 05:49 AM
  5. [SOLVED] Auto-Fill names based on a Validation?
    By aiwnjoo in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 04-28-2010, 01:01 PM
  6. Auto fill-in based on drop-down list
    By bigchalk in forum Excel General
    Replies: 2
    Last Post: 02-23-2010, 05:18 PM
  7. Auto fill a range based on another cell
    By Ricardo9211 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 07-29-2009, 04:58 PM
  8. auto fill state and city from phone number?
    By Biz in forum Excel General
    Replies: 2
    Last Post: 11-18-2005, 02:52 PM

Tags for this Thread

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