+ Reply to Thread
Results 1 to 6 of 6

VBA: Autofill blank cells between ones with entries

  1. #1
    Registered User
    Join Date
    03-15-2015
    Location
    Espaņa
    MS-Off Ver
    2013
    Posts
    80

    VBA: Autofill blank cells between ones with entries

    Hello there,

    I have the following dataset:

    City Neighborhood
    City 1 Some place
    City 1 Another one
    City 1 Anywhere
    City 1
    City 1
    City 2
    City 2
    City 2
    City 2
    City 3 Everywhere
    City 3
    City 3
    City 3


    It contains one column that sometimes has data, sometimes it doesn't. It depends on the City column.

    I'd like to know how could I autofill the blank cells with two possible values:

    1. Other
    -OR-
    2. Doesn't apply

    Other when the cell belongs to a City that DOES have neighborhoods
    Doesn't apply when the cell belongs to a City that DOES NOT have neighborhood.

    The end result looking like this:
    City Neighborhood
    City 1 Some place
    City 1 Another one
    City 1 Anywhere
    City 1 Other
    City 1 Other
    City 2 Doesn't Apply
    City 2 Doesn't Apply
    City 2 Doesn't Apply
    City 2 Doesn't Apply
    City 3 Everywhere
    City 3 Other
    City 3 Other
    City 3 Other

    Any advise?

    I have attached the original table. It does not contain any sensitive data. The columns related to this issue are colored in yellow.

    Thank you very much for your help!
    Attached Files Attached Files
    Last edited by elbrujo; 09-23-2019 at 01:18 PM. Reason: solved

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,780

    Re: Autofill blank cells

    This can't be done without VBA - shall I move the thread for you?
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Registered User
    Join Date
    03-15-2015
    Location
    Espaņa
    MS-Off Ver
    2013
    Posts
    80
    Oh, Okay AliGW. Thank you!
    Last edited by AliGW; 09-22-2019 at 03:57 AM. Reason: Please don't quote unnecessarily!

  4. #4
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,230

    Re: VBA: Autofill blank cells between ones with entries

    Here's one way...
    Please Login or Register  to view this content.
    Good Luck
    I don't presume to know what I am doing, however, just like you, I too started somewhere...
    One-day, One-problem at a time!!!
    If you feel I have helped, please click on the star to left of post [Add Reputation]
    Also....add a comment if you like!!!!
    And remember...Mark Thread as Solved.
    Excel Forum Rocks!!!

  5. #5
    Registered User
    Join Date
    03-15-2015
    Location
    Espaņa
    MS-Off Ver
    2013
    Posts
    80

    Re: VBA: Autofill blank cells between ones with entries

    Hello @sintek. Thank you very much! It works perfectly fine.

    Thanks for your help once again. Have a great day!

  6. #6
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,230

    Re: VBA: Autofill blank cells between ones with entries

    Glad i could help...Tx for rep...please mark thread as solved...

+ 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] Search Entries & Autofill Cells With Specified Data
    By swordswinger710 in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 07-08-2016, 08:30 AM
  2. [SOLVED] Autofill blank cell from one of three other cells in same row
    By AF1HS in forum Excel General
    Replies: 3
    Last Post: 01-04-2015, 10:55 PM
  3. [SOLVED] Autofill blank cells in column A
    By longbow007 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 05-02-2013, 06:54 AM
  4. Autofill blank cells
    By Vestlink in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 04-18-2012, 08:11 AM
  5. Autofill blank cells
    By tuganne1 in forum Excel General
    Replies: 2
    Last Post: 07-08-2009, 01:52 PM
  6. [SOLVED] Need macro to autofill when there are blank cells
    By Christy in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-06-2006, 03:35 PM
  7. Autofill blank cells
    By nek0 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 03-15-2005, 09:49 AM

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